Re: [HACKERS] COPY CSV keywords

2004-04-20 Thread Andrew Dunstan
Bruce Momjian wrote: [ discussion moved to hackers.] Peter Eisentraut wrote: Bruce Momjian wrote: I have applied the attached patch that complete TODO item: o -Allow dump/load of CSV format This adds new keywords to COPY and \copy: CSV - enable CSV mode QUOTE - spe

Re: [HACKERS] COPY CSV keywords

2004-04-20 Thread Andrew Dunstan
I wrote: The problem is that using QUOTE or NULL in these phrases might look confusing, e.g. COPY mytable TO 'mytable.csv' CSV QUOTE '"' FORCE QUOTE field1,field2; COPY mytable FROM 'mytable.csv' NULL '' CSV NO NULL CHECK field1,field2; I also don't think NO NULL CHECK actually matches the use

Re: [HACKERS] COPY CSV keywords

2004-04-20 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > Peter Eisentraut wrote: >> Bruce Momjian wrote: >>> LITERAL - prevent NULL checks for specific columns >> >> NO NULL CHECK > I considered going this direction, but it broke the WITH clause style of > COPY. Huh? Many of the other options are already po

Re: [HACKERS] COPY CSV keywords

2004-04-20 Thread Bruce Momjian
Tom Lane wrote: > Bruce Momjian <[EMAIL PROTECTED]> writes: > > Peter Eisentraut wrote: > >> Bruce Momjian wrote: > >>> LITERAL - prevent NULL checks for specific columns > >> > >> NO NULL CHECK > > > I considered going this direction, but it broke the WITH clause style of > > COPY. > > Huh? Ma