Hi Tom -
Thanks for the suggestions. You were correct, and it was a combination of
problems. The field delimiter was a tab, and there were text fields that
ended with a \, so of course that caused problems. There were also single
quotes in the text fields, but they didn't occur in pairs. Rather they were
possessive case nouns. And finally there were double quotes. And, oddly
enough, they didn't always occur in pairs. In fact, sometimes the double
quote was the only character in the text field. The double quotes didn't
turn out to be a problem.
I did the following.
1) replaced all \tab combinations with blankTab.
2) replaced all 's with two single quotes, '', because \' doesn't work in a
Following this, everything loaded just fine.
Thank you again for you help, and for pointing me in the right direction.
On 3/28/07, James Long <pgsql-novice(at)museum(dot)rain(dot)com> wrote:
> On Wed, Mar 28, 2007 at 10:15:35AM -0400, Tom Lane wrote:
> > "David Monarchi" <david(dot)e(dot)monarchi(at)gmail(dot)com> writes:
> > > Each line is terminated with a LF (0A), including the last line. This
> > > the structure that of all of the other files that I can load have.
> > > Some of the text fields in the file had \ in them, so I simply
> replaced all
> > > of them with blanks to see if somewhere there was an escape sequence
> > > was causing the problem.
> > Hm ... AFAICS from looking at the code, it's impossible to get that
> > error message unless the file contains \ followed by . followed by
> > something that's not either CR or LF.
> What is the output of:
> grep -c "\\\."
> and if that is a "small" number, the output of:
> grep -n "\\\."
> grep "\\\." | hexdump -C
In response to
pgsql-novice by date
|Next:||From: Michael||Date: 2007-03-30 21:38:53|
|Subject: rounding down a number|
|Previous:||From: Sandeep Agarwal||Date: 2007-03-30 05:32:01|
|Subject: Re: Data Encryption|