Re: COPY FROM WITH HEADER skips a tuple every 4 billion tuples - Mailing list pgsql-hackers

From Tom Lane
Subject Re: COPY FROM WITH HEADER skips a tuple every 4 billion tuples
Date
Msg-id 10484.1527007495@sss.pgh.pa.us
Whole thread Raw
In response to Re: COPY FROM WITH HEADER skips a tuple every 4 billion tuples  (Andres Freund <andres@anarazel.de>)
List pgsql-hackers
Andres Freund <andres@anarazel.de> writes:
> On 2018-05-22 11:55:26 -0400, Tom Lane wrote:
>> Hm, so why is the correct rowcount returned --- are we running
>> a separate counter for that purpose, and if so why?

> Yes, it's a local counter in CopyFrom/CopyTo.  It's probably not
> entirely trivial to unify the two. The batching etc makes us modify
> cur_lineno in a bit weird ways at times.

OK, we'll just do it like David suggests then.  I haven't checked the
patch in detail yet, but it seemed generally sane if we're just going
to widen the duplicate counter.

            regards, tom lane


pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: plperl fails with perl 5.28
Next
From: Andres Freund
Date:
Subject: Re: Postgres, fsync, and OSs (specifically linux)