From: | Bernd Helmle <mailings(at)oopsware(dot)de> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Passing fdw_private data from PlanForeignScan to PlanForeignModify |
Date: | 2013-06-13 12:02:54 |
Message-ID: | 5B403C914B5ED69C995AB8C4@apophis.credativ.lan |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
I'm currently implementing DML actions in the informix FDW module and
trying to understand how UPDATE/DELETE actions interact with the various
structures, especially how states between the associated ForeignScan and
ForeignModify actions could be transmitted. As far as i understood, with
e.g. an UPDATE action on a foreign table you get the following sequence of
callbacks:
GetForeignRelSize
GetForeignPaths
GetForeignPlan
PlanForeignModify
BeginForeignScan
BeginForeignModify
<repeats>
IterateForeignScan
ExecForeignUpdate
</repeats>
EndForeignScan
EndForeignModify
During the planning phase, the Informix FDW currently plans a server side
cursor, which identifier i'd like to pass into the planning phase of the
modify action to reuse it in conjunction with UPDATE ... WHERE CURRENT OF.
I understand that the ModifyTable structure passed to PlanForeignModify has
a list of associated plan nodes, from which i can access the ForeignScan
plan node associated with the current modify action, thus having access to
the fdw_private data generated during the planning phase of the ForeigScan
node. However, it's a list and i currently don't understand on how to
reference the associated ForeignScan node reliably, given that there are
cases with more than one node in this list.
Any pointers, someone?
--
Thanks
Bernd
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Kapila | 2013-06-13 12:35:17 | ALTER SYSTEM SET command to change postgresql.conf parameters (RE: Proposal for Allow postgresql.conf values to be changed via SQL [review]) |
Previous Message | Ants Aasma | 2013-06-13 10:16:18 | Re: Parallell Optimizer |