diff options
author | Peter Eisentraut <peter_e@gmx.net> | 2018-11-15 23:04:48 +0100 |
---|---|---|
committer | Peter Eisentraut <peter_e@gmx.net> | 2018-11-15 23:06:29 +0100 |
commit | 59f372e082e6564f4629dcbbc235c206e963814d (patch) | |
tree | ef9d93b61629dfe7c458a7c847f5d4b648091cae /src | |
parent | fd5274a65b4fe15c4b8dd66ef6839dc1dbf86a52 (diff) | |
download | postgresql-59f372e082e6564f4629dcbbc235c206e963814d.tar.gz postgresql-59f372e082e6564f4629dcbbc235c206e963814d.zip |
Correct code comments for PartitionedRelPruneInfo struct
The comments above the PartitionedRelPruneInfo struct incorrectly
document how subplan_map and subpart_map are indexed. This seems to
have snuck in on 4e232364033.
Author: David Rowley <david.rowley@2ndquadrant.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/include/nodes/plannodes.h | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/src/include/nodes/plannodes.h b/src/include/nodes/plannodes.h index cb2547c1639..249aa6520a0 100644 --- a/src/include/nodes/plannodes.h +++ b/src/include/nodes/plannodes.h @@ -1089,15 +1089,16 @@ typedef struct PartitionPruneInfo * PartitionedRelPruneInfo - Details required to allow the executor to prune * partitions for a single partitioned table. * - * subplan_map[] and subpart_map[] are indexed by partition index (where - * zero is the topmost partition, and non-leaf partitions must come before - * their children). For a leaf partition p, subplan_map[p] contains the - * zero-based index of the partition's subplan in the parent plan's subplan - * list; it is -1 if the partition is non-leaf or has been pruned. For a - * non-leaf partition p, subpart_map[p] contains the zero-based index of - * that sub-partition's PartitionedRelPruneInfo in the hierarchy's - * PartitionedRelPruneInfo list; it is -1 if the partition is a leaf or has - * been pruned. Note that subplan indexes are global across the parent plan + * subplan_map[] and subpart_map[] are indexed by partition index of the + * partitioned table referenced by 'rtindex', the partition index being the + * order that the partitions are defined in the table's PartitionDesc. For a + * leaf partition p, subplan_map[p] contains the zero-based index of the + * partition's subplan in the parent plan's subplan list; it is -1 if the + * partition is non-leaf or has been pruned. For a non-leaf partition p, + * subpart_map[p] contains the zero-based index of that sub-partition's + * PartitionedRelPruneInfo in the hierarchy's PartitionedRelPruneInfo list; + * it is -1 if the partition is a leaf or has been pruned. Note that subplan + * indexes, as stored in 'subplan_map', are global across the parent plan * node, but partition indexes are valid only within a particular hierarchy. */ typedef struct PartitionedRelPruneInfo |