On Thursday 29 November 2007 2:40 pm, Ivan Sergio Borgonovo wrote:
> On Tue, 27 Nov 2007 21:12:00 -0500
>
> Lew <[EMAIL PROTECTED]> wrote:
> > Lew wrote:
> > >> Try eliminating the double quotes in the CSV file. "Wannabe"
> > >> NULL would then be ,, (consecutive commas)
> > >> in the CSV. From t
On Tue, 27 Nov 2007 21:12:00 -0500
Lew <[EMAIL PROTECTED]> wrote:
> Lew wrote:
> >> Try eliminating the double quotes in the CSV file. "Wannabe"
> >> NULL would then be ,, (consecutive commas)
> >> in the CSV. From the docs, you don't even need the "NULL AS"
> >> clause in your COPY statement.
>
Lew wrote:
Try eliminating the double quotes in the CSV file. "Wannabe" NULL
would then be ,, (consecutive commas)
in the CSV. From the docs, you don't even need the "NULL AS"
clause in your COPY statement.
Ivan Sergio Borgonovo wrote:
Exactly what I did because fortunately there weren't too
On Sun, 25 Nov 2007 13:22:48 -0500
Lew <[EMAIL PROTECTED]> wrote:
> I went to the docs for COPY and they say,
> > The default is \N (backslash-N) in text mode, and a empty value
> > with no quotes in CSV mode.
> That "with no quotes" phrase caught my attention.
> Try eliminating the double quote
Ivan Sergio Borgonovo wrote:
I'd expect this:
\copy tablename from 'filename.csv' WITH NULL as '' CSV HEADER
whould import "" as NULL.
The input file is UTF-8 (not Unicode/UTF-16).
I checked the hexdump and the "wannabe" NULL are actually
2c 22 22 2c -> ,"",
all fields are varchar that admit
I'd expect this:
\copy tablename from 'filename.csv' WITH NULL as '' CSV HEADER
whould import "" as NULL.
The input file is UTF-8 (not Unicode/UTF-16).
I checked the hexdump and the "wannabe" NULL are actually
2c 22 22 2c -> ,"",
all fields are varchar that admit NULL
but still I get empty str