Re: restore whoes

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: Simone Tellini <tellini(at)areabusiness(dot)it>, pgsql-admin(at)postgresql(dot)org
Subject: Re: restore whoes
Date: 2002-02-11 19:24:18
Message-ID: 12608.1013455458@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> Well, if the COPY fails on the last value of the first row, and that
> value has a trailing \r, we can be pretty sure.

In the examples given, the error didn't show up till later rows, in
fields where there was no \r anywhere.

> I don't see how your
> solution make it fool-proof, except by requiring every COPY file, old
> and new, and created, to have CR as \r.

There *is no* foolproof solution with the current data representation
(and your idea of throwing untrustworthy error messages is certainly not
foolproof). What we need to do is migrate to a new data representation.
Fortunately, it's nearly there already, since \ r and \ n sequences are
already supported by COPY IN.

regards, tom lane

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Bruce Momjian 2002-02-11 19:59:52 Re: restore whoes
Previous Message Bruce Momjian 2002-02-11 19:17:54 Re: restore whoes