Skip site navigation (1) Skip section navigation (2)

Re: copy error

From: "Keith Worthington" <keithw(at)narrowpathinc(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Michael Fuhr <mike(at)fuhr(dot)org>
Cc: PostgreSQL Novice <pgsql-novice(at)postgresql(dot)org>
Subject: Re: copy error
Date: 2004-10-15 15:07:50
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-novice
> Michael Fuhr <mike(at)fuhr(dot)org> writes:
> > I'd guess that there's a carriage return at the end of line 1.
> Looks like that to me too.
> > You might need to run your data through a filter before importing
> > it into PostgreSQL.  Some systems have a dos2unix program; you could
> > also use tr, sed, perl, awk, etc. to strip trailing carriage returns.
> Alternatively, update to PG 7.4 or later.  Since 7.4 COPY will 
> attempt to Do The Right Thing with files containing Windows-style newlines.
> 			regards, tom lane

It turns out there was a carrige return at the end of every line.  Thasnk for
the help.

Kind Regards,

99main Internet Services

In response to

pgsql-novice by date

Next:From: Kumar SDate: 2004-10-15 21:15:45
Subject: syntax error at or near "Hs" at character 1182
Previous:From: Tom LaneDate: 2004-10-15 14:55:48
Subject: Re: copy error

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group