diff options
author | Amit Langote <amitlan@postgresql.org> | 2025-02-25 09:21:17 +0900 |
---|---|---|
committer | Amit Langote <amitlan@postgresql.org> | 2025-02-25 09:24:42 +0900 |
commit | cbb9086c9ef64b020cb9036f50afc14644bbf734 (patch) | |
tree | 215c47330d68db022a29bfab45279a14f3292ae3 /src/backend/access/transam/xlogutils.c | |
parent | 48796a98d5aed68e349118d4e05ac26b76c765b0 (diff) | |
download | postgresql-cbb9086c9ef64b020cb9036f50afc14644bbf734.tar.gz postgresql-cbb9086c9ef64b020cb9036f50afc14644bbf734.zip |
Fix bug in cbc127917 to handle nested Append correctly
A non-leaf partition with a subplan that is an Append node was
omitted from PlannedStmt.unprunableRelids because it was mistakenly
included in PlannerGlobal.prunableRelids due to the way
PartitionedRelPruneInfo.leafpart_rti_map[] is constructed. This
happened when a non-leaf partition used an unflattened Append or
MergeAppend. As a result, ExecGetRangeTableRelation() reported an
error when called from CreatePartitionPruneState() to process the
partition's own PartitionPruneInfo, since it was treated as prunable
when it should not have been.
Reported-by: Alexander Lakhin <exclusion@gmail.com> (via sqlsmith)
Diagnosed-by: Tender Wang <tndrwang@gmail.com>
Reviewed-by: Tender Wang <tndrwang@gmail.com>
Discussion: https://postgr.es/m/74839af6-aadc-4f60-ae77-ae65f94bf607@gmail.com
Diffstat (limited to 'src/backend/access/transam/xlogutils.c')
0 files changed, 0 insertions, 0 deletions