file_textarray_fdw
file_textarray_fdw · Foreign data wrapper returning each text-file row as a text array.
Overview
| ID | Extension | Package | Version | Category | License | Language |
|---|---|---|---|---|---|---|
| 100092 | file_textarray_fdw | file_textarray_fdw | 1.0.1 | FDW | PostgreSQL | C |
Usage
Sources:
file_textarray_fdw version 1.0.1 reads server-side files whose rows may have different numbers of fields. Each parsed row is returned through one text[] column instead of requiring a fixed foreign-table column list.
Core Workflow
The sole foreign-table column must be text[]. Fields are placed into the array in file order, so callers can index and cast only the positions they need.
Options and Boundaries
The wrapper accepts the file parsing options implemented by PostgreSQL’s file FDW machinery, including filename, format, header, delimiter, quote, escape, and null. The filename is on the PostgreSQL server, not the client. The server operating-system account must be able to read it.
This FDW implements scans only: it does not write back to the file. Grant server and foreign-table privileges carefully, because access can expose files readable by the PostgreSQL service account. No user mapping, preload, or restart is required.