Julian Hyde created CALCITE-1995:
------------------------------------
Summary: Remove predicates from Filter if they can be proved to be
always true or false
Key: CALCITE-1995
URL: https://issues.apache.org/jira/browse/CALCITE-1995
Project: Calcite
Issue Type: Bug
Reporter: Julian Hyde
Assignee: Julian Hyde
Remove predicates from Filter if they can be proved to be always true or false.
For example, the query
{code}
select *
from (select * from emp where deptno > 10)
where empno > 3 and deptno > 5
{code}
can be simplified to
{code}
select *
from (select * from emp where deptno > 10)
where empno > 3
{code}
because {{deptno > 5}} can be proved to be always true, due the predicate
{{deptno > 10}} on its input relational expression.
Implement this by expanding the capabilities of {{FilterReduceExpressionsRule}}.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)