Re: Using COPY

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: joe(at)jwebmedia(dot)com
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Using COPY
Date: 2002-05-14 15:04:12
Message-ID: 26117.1021388652@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Joseph Koenig <joe(at)jwebmedia(dot)com> writes:
> We're converting a db from Access to PostgreSQL for a client - I need to
> export all of his data into postgres on Linux - I'm trying to use the
> COPY command, however, his comment fields have line breaks in them which
> causes the copy to throw a parse error at that line. I'm sure others
> have run into this - is there an easy way to avoid this? Thanks,

You'll need to transform the linebreaks that should be data into \n
(backslash-n) or \LF (backslash-newline) sequences.

regards, tom lane

In response to

  • Using COPY at 2002-05-14 14:15:05 from Joseph Koenig

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Martín Marqués 2002-05-14 15:05:22 Re: restoreing dumps fail
Previous Message Martijn van Oosterhout 2002-05-14 14:54:16 Re: transitioning postgres oid