diff options
| author | Simon Riggs <simon@2ndQuadrant.com> | 2018-04-05 09:54:07 +0100 |
|---|---|---|
| committer | Simon Riggs <simon@2ndQuadrant.com> | 2018-04-05 09:54:07 +0100 |
| commit | 4b2d44031f8c005f6f86364d7663858b6b5bdd14 (patch) | |
| tree | 821dec0027fe8caa8ce50250e20a1e594d738e7e /src/backend/executor/README | |
| parent | 1fd8690668635bab9dfa16b2885e6e474f8451ba (diff) | |
MERGE post-commit review
Review comments from Andres Freund
* Consolidate code into AfterTriggerGetTransitionTable()
* Rename nodeMerge.c to execMerge.c
* Rename nodeMerge.h to execMerge.h
* Move MERGE handling in ExecInitModifyTable()
into a execMerge.c ExecInitMerge()
* Move mt_merge_subcommands flags into execMerge.h
* Rename opt_and_condition to opt_merge_when_and_condition
* Wordsmith various comments
Author: Pavan Deolasee
Reviewer: Simon Riggs
Diffstat (limited to 'src/backend/executor/README')
| -rw-r--r-- | src/backend/executor/README | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/backend/executor/README b/src/backend/executor/README index 05769772b77..7882ce44e78 100644 --- a/src/backend/executor/README +++ b/src/backend/executor/README @@ -39,13 +39,14 @@ ModifyTable node visits each of those rows and marks the row deleted. MERGE runs one generic plan that returns candidate target rows. Each row consists of a super-row that contains all the columns needed by any of the -individual actions, plus a CTID and a TABLEOID junk columns. The CTID column is +individual actions, plus CTID and TABLEOID junk columns. The CTID column is required to know if a matching target row was found or not and the TABLEOID column is needed to find the underlying target partition, in case when the -target table is a partition table. If the CTID column is set we attempt to -activate WHEN MATCHED actions, or if it is NULL then we will attempt to -activate WHEN NOT MATCHED actions. Once we know which action is activated we -form the final result row and apply only those changes. +target table is a partition table. When a matching target tuple is found, the +CTID column identifies the matching target tuple and we attempt to activate +WHEN MATCHED actions. If a matching tuple is not found, then CTID column is +NULL and we attempt to activate WHEN NOT MATCHED actions. Once we know which +action is activated we form the final result row and apply only those changes. XXX a great deal more documentation needs to be written here... |
