partprune-1c2cb2744-thinko.patch

text/plain

Filename: partprune-1c2cb2744-thinko.patch
Type: text/plain
Part: 0
Message: Re: Internal error XX000 with enable_partition_pruning=on, pg 11 beta1 on Debian

Patch

Same data as JSON: GET /api/v1/attachments/:id/patch the parsed metadata as JSON — format, series position, per-file stats; never the diff bytes. API reference →
Format: unified
File+
src/backend/partitioning/partprune.c 1 1
diff --git a/src/backend/partitioning/partprune.c b/src/backend/partitioning/partprune.c
index 752810d0e4..67f0dc5e59 100644
--- a/src/backend/partitioning/partprune.c
+++ b/src/backend/partitioning/partprune.c
@@ -384,7 +384,7 @@ make_partitionedrel_pruneinfo(PlannerInfo *root, RelOptInfo *parentrel,
 			 * because in later iterations of the loop for child partitions,
 			 * we want to translate from parent to child variables.
 			 */
-			if (parentrel != subpart)
+			if (parentrel->relid != subpart->relid)
 			{
 				int			nappinfos;
 				AppendRelInfo **appinfos = find_appinfos_by_relids(root,