aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2018-08-08 20:02:10 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2018-08-08 20:02:32 -0400
commit59ef49d26d2f8724d0788fea0774f786a22ca63d (patch)
treeb8bb089745f8d5bc95a523186b8cecbdcbf53941
parent313cbdc7f666a5af2c977463faf8a0eb06011b98 (diff)
downloadpostgresql-59ef49d26d2f8724d0788fea0774f786a22ca63d.tar.gz
postgresql-59ef49d26d2f8724d0788fea0774f786a22ca63d.zip
Remove bogus Assert in make_partitionedrel_pruneinfo().
This Assert thought that a given rel couldn't be both leaf and non-leaf, but it turns out that in some unusual plan trees that's wrong, so remove it. The lack of testing for cases like that is quite concerning --- there is little reason for confidence that there aren't other bugs in the area. But developing a stable test case seems rather difficult, and in any case we don't need this Assert. David Rowley Discussion: https://postgr.es/m/CAJGNTeOkdk=UVuMugmKL7M=owgt4nNr1wjxMg1F+mHsXyLCzFA@mail.gmail.com
-rw-r--r--src/backend/partitioning/partprune.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/src/backend/partitioning/partprune.c b/src/backend/partitioning/partprune.c
index 7fb53e6446d..0dd55ac1ba3 100644
--- a/src/backend/partitioning/partprune.c
+++ b/src/backend/partitioning/partprune.c
@@ -347,8 +347,6 @@ make_partitionedrel_pruneinfo(PlannerInfo *root, RelOptInfo *parentrel,
Assert(rti < root->simple_rel_array_size);
/* No duplicates please */
Assert(relid_subpart_map[rti] == 0);
- /* Same rel cannot be both leaf and non-leaf */
- Assert(relid_subplan_map[rti] == 0);
relid_subpart_map[rti] = i++;
}