mirror of
https://github.com/postgres/postgres.git
synced 2025-07-15 19:21:59 +03:00
Fire per-statement triggers on partitioned tables.
Even though no actual tuples are ever inserted into a partitioned table (the actual tuples are in the partitions, not the partitioned table itself), we still need to have a ResultRelInfo for the partitioned table, or per-statement triggers won't get fired. Amit Langote, per a report from Rajkumar Raghuwanshi. Reviewed by me. Discussion: http://postgr.es/m/CAKcux6%3DwYospCRY2J4XEFuVy0L41S%3Dfic7rmkbsU-GXhhSbmBg%40mail.gmail.com
This commit is contained in:
@ -91,6 +91,7 @@ _copyPlannedStmt(const PlannedStmt *from)
|
||||
COPY_NODE_FIELD(rtable);
|
||||
COPY_NODE_FIELD(resultRelations);
|
||||
COPY_NODE_FIELD(nonleafResultRelations);
|
||||
COPY_NODE_FIELD(rootResultRelations);
|
||||
COPY_NODE_FIELD(subplans);
|
||||
COPY_BITMAPSET_FIELD(rewindPlanIDs);
|
||||
COPY_NODE_FIELD(rowMarks);
|
||||
@ -205,6 +206,7 @@ _copyModifyTable(const ModifyTable *from)
|
||||
COPY_NODE_FIELD(partitioned_rels);
|
||||
COPY_NODE_FIELD(resultRelations);
|
||||
COPY_SCALAR_FIELD(resultRelIndex);
|
||||
COPY_SCALAR_FIELD(rootResultRelIndex);
|
||||
COPY_NODE_FIELD(plans);
|
||||
COPY_NODE_FIELD(withCheckOptionLists);
|
||||
COPY_NODE_FIELD(returningLists);
|
||||
|
Reference in New Issue
Block a user