diff options
-rw-r--r-- | src/backend/optimizer/path/equivclass.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/backend/optimizer/path/equivclass.c b/src/backend/optimizer/path/equivclass.c index 2c595dfb08c..ccc07ba9f0d 100644 --- a/src/backend/optimizer/path/equivclass.c +++ b/src/backend/optimizer/path/equivclass.c @@ -761,7 +761,8 @@ get_eclass_for_sort_expr(PlannerInfo *root, { RelOptInfo *rel = root->simple_rel_array[i]; - Assert(rel->reloptkind == RELOPT_BASEREL); + Assert(rel->reloptkind == RELOPT_BASEREL || + rel->reloptkind == RELOPT_DEADREL); rel->eclass_indexes = bms_add_member(rel->eclass_indexes, ec_index); |