Re: [HACKERS] COPY and file_fdw with fixed column widths

2015-04-28 Thread Andrew Dunstan
On 04/28/2015 03:50 PM, Bruce Momjian wrote: On Tue, Apr 28, 2015 at 12:46:22PM -0700, Tom Lane wrote: Bruce Momjian writes: I know COPY doesn't support importing files with fixed column widths, i.e. we can't say field1 is the first 30 characters, and field2 is the rest of the line. We need

Re: [HACKERS] COPY and file_fdw with fixed column widths

2015-04-28 Thread Bruce Momjian
On Tue, Apr 28, 2015 at 12:46:22PM -0700, Tom Lane wrote: > Bruce Momjian writes: > > I know COPY doesn't support importing files with fixed column widths, > > i.e. we can't say field1 is the first 30 characters, and field2 is the > > rest of the line. We need a unique delimiter at column 31. (C

Re: [HACKERS] COPY and file_fdw with fixed column widths

2015-04-28 Thread Tom Lane
Bruce Momjian writes: > I know COPY doesn't support importing files with fixed column widths, > i.e. we can't say field1 is the first 30 characters, and field2 is the > rest of the line. We need a unique delimiter at column 31. (Commercial > Ingres does support this ability.) > I know we tell m

[HACKERS] COPY and file_fdw with fixed column widths

2015-04-28 Thread Bruce Momjian
I know COPY doesn't support importing files with fixed column widths, i.e. we can't say field1 is the first 30 characters, and field2 is the rest of the line. We need a unique delimiter at column 31. (Commercial Ingres does support this ability.) I know we tell most people to use sed, Perl, or a