Re: Parallel INSERT (INTO ... SELECT ...) - Mailing list pgsql-hackers

From Thomas Munro
Subject Re: Parallel INSERT (INTO ... SELECT ...)
Date
Msg-id CA+hUKGJo6-H1LVQEvorf+djjmsu7sMM4fT9rpsm2seYesikPdw@mail.gmail.com
Whole thread Raw
In response to Re: Parallel INSERT (INTO ... SELECT ...)  (Greg Nancarrow <gregn4422@gmail.com>)
Responses Re: Parallel INSERT (INTO ... SELECT ...)
List pgsql-hackers
On Mon, Oct 12, 2020 at 3:42 PM Greg Nancarrow <gregn4422@gmail.com> wrote:
> On Sun, Oct 11, 2020 at 1:39 PM Thomas Munro <thomas.munro@gmail.com> wrote:
> >                 pathnode->path.total_cost += subpath->total_cost;
> > -               pathnode->path.rows += subpath->rows;
> > +               if (returningLists != NIL)
> > +                       pathnode->path.rows += subpath->rows;
> >                 total_size += subpath->pathtarget->width * subpath->rows;
> >         }

Erm, except the condition should of course cover total_size too.

> Agree, thanks (bug in existing Postgres code, right?)

Yeah, I think we should go ahead and fix that up front.  Here's a
version with a commit message.

Attachment

pgsql-hackers by date:

Previous
From: Amit Kapila
Date:
Subject: Re: [PATCH] Add `truncate` option to subscription commands
Next
From: Tom Lane
Date:
Subject: Re: BUG #15858: could not stat file - over 4GB