Andres Freund <and...@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