Re: Copy From with "null" data

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "James Moe" <jimoe(at)sohnen-moe(dot)com>
Cc: "Postgresql General Mail List" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Copy From with "null" data
Date: 2003-08-16 13:04:18
Message-ID: 24639.1061039058@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

"James Moe" <jimoe(at)sohnen-moe(dot)com> writes:
> this bizarre error message is produced in psql:

> ": can't parse "ne 1, pg_atoi: error in "1

That's unrelated to your NULL issue. It looks like you have
Windows-style newlines (\r\n) in your data. COPY only likes
Unix-style newlines (\n). It thinks the \r is a data character.

I think this is finally relaxed for 7.4, but in all current releases
you need to get rid of the carriage return characters.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Murthy Kambhampaty 2003-08-16 13:43:13 Re: summary and request
Previous Message Tom Lane 2003-08-16 12:21:05 Re: New to list, quick question.