Re: postgres_fdw: batch inserts vs. before row triggers - Mailing list pgsql-hackers

From Etsuro Fujita
Subject Re: postgres_fdw: batch inserts vs. before row triggers
Date
Msg-id CAPmGK17rmXEY3BL=Aq71L8UZv5f-mz=uxJkz1kMnfSSY+pFe-A@mail.gmail.com
Whole thread Raw
In response to Re: postgres_fdw: batch inserts vs. before row triggers  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: postgres_fdw: batch inserts vs. before row triggers
List pgsql-hackers
On Sun, Nov 27, 2022 at 12:11 AM Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Etsuro Fujita <etsuro.fujita@gmail.com> writes:
> > On Sat, Nov 26, 2022 at 1:57 AM Tom Lane <tgl@sss.pgh.pa.us> wrote:
> >> Couldn't we add the field to ModifyTableState, instead?
>
> > We could probably do so, but I thought having a global list would be
> > more efficient to handle pending buffered inserts than that.
>
> OK, as long as there's a reason for doing it that way, it's OK
> by me.  I don't think that adding a field at the end of EState
> is an ABI problem.
>
> We have to do something else than add to ResultRelInfo, though.

OK, I removed from ResultRelInfo a field that I added in the commit to
save the owning ModifyTableState if insert-pending, and added to
EState another List member to save such ModifyTableStates, instead.  I
am planning to apply this to not only back branches but HEAD, to make
back-patching easy, if there are no objections.

Best regards,
Etsuro Fujita

Attachment

pgsql-hackers by date:

Previous
From: Himanshu Upadhyaya
Date:
Subject: Re: HOT chain validation in verify_heapam()
Next
From: Daniel Gustafsson
Date:
Subject: Re: pg_dump: Remove "blob" terminology