jackylau created CALCITE-3669: --------------------------------- Summary: logical plan optimizer test not correct Key: CALCITE-3669 URL: https://issues.apache.org/jira/browse/CALCITE-3669 Project: Calcite Issue Type: Improvement Reporter: jackylau
we can see blow from RelOptRulesTest.java it validates for testEmptySort, but this rule will not be fired. and it should add PruneEmptyRules.PROJECT_INSTANCE will fire it. Sort -> Project -> Filter -> Scan will be Sort ->Project ->Value(empty) by ReduceExpressionsRule.FILTER_INSTANCE @Test public void testEmptySort() { HepProgram program = new HepProgramBuilder() .addRuleInstance(ReduceExpressionsRule.FILTER_INSTANCE) .addRuleInstance(PruneEmptyRules.SORT_INSTANCE) .build(); checkPlanning(program, "select * from emp where false order by deptno"); } -- This message was sent by Atlassian Jira (v8.3.4#803005)