Re: [HACKERS] exactly what is COPY BOTH mode supposed to do in case of an error?

2013-04-27 Thread Simon Riggs
On 27 April 2013 20:12, Robert Haas wrote: > My feeling is that it would be better not to back-patch this, but just > fix it in master. Given the present uses of COPY-BOTH mode, the > problems seem to be limited to bad error messages, so it's arguably > not a critical bug fix. Also, I think tha

Re: [HACKERS] exactly what is COPY BOTH mode supposed to do in case of an error?

2013-04-27 Thread Robert Haas
On Sat, Apr 27, 2013 at 6:02 AM, Simon Riggs wrote: > On 27 April 2013 03:22, Robert Haas wrote: >> It seems the backend and libpq don't agree. The backend makes no >> special provision to wait for a CopyDone message if an error occurs >> during copy-both. It simply sends an ErrorResponse and t

Re: [HACKERS] exactly what is COPY BOTH mode supposed to do in case of an error?

2013-04-27 Thread Tom Lane
Simon Riggs writes: > libpq updates are much harder to roll out, so it would be better to > assume that it is correct and the backend is wrong if we want to > backpatch the fix. I don't think that's a particularly sound argument. If we view this as a protocol definitional issue, which it is, the

Re: [HACKERS] exactly what is COPY BOTH mode supposed to do in case of an error?

2013-04-27 Thread Simon Riggs
On 27 April 2013 03:22, Robert Haas wrote: > It seems the backend and libpq don't agree. The backend makes no > special provision to wait for a CopyDone message if an error occurs > during copy-both. It simply sends an ErrorResponse and that's it. > libpq, on the other hand, treats either CopyD

[HACKERS] exactly what is COPY BOTH mode supposed to do in case of an error?

2013-04-26 Thread Robert Haas
It seems the backend and libpq don't agree. The backend makes no special provision to wait for a CopyDone message if an error occurs during copy-both. It simply sends an ErrorResponse and that's it. libpq, on the other hand, treats either CopyDone or ErrorResponse as a cue to transition to PGASYN