Skip to content

Commit fcc4735

Browse files
committed
Run empty values node simplify optimizer after connector optimizer
1 parent 484b00e commit fcc4735

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

presto-main-base/src/main/java/com/facebook/presto/sql/planner/PlanOptimizers.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -957,6 +957,9 @@ public PlanOptimizers(
957957
costCalculator,
958958
ImmutableSet.of(new RemoveRedundantIdentityProjections(), new PruneRedundantProjectionAssignments())));
959959

960+
// Pass after connector optimizer, as it relies on connector optimizer to identify empty input tables and convert them to empty ValuesNode
961+
builder.add(new SimplifyPlanWithEmptyInput());
962+
960963
// DO NOT add optimizers that change the plan shape (computations) after this point
961964

962965
// Precomputed hashes - this assumes that partitioning will not change

0 commit comments

Comments
 (0)