-
Type:
New Feature
-
Status: Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: 0.9.0-incubating
-
Component/s: None
-
Labels:None
This is along the lines of the TransitivePredicate inference Rule in Hive.
For e.g. for
select 1 from sales.emp d inner join sales.emp e
on d.deptno = e.deptno where e.deptno > 7
we can infer
ProjectRel(EXPR$0=[1])
JoinRel(condition=[=($7, $16)], joinType=[inner])
FilterRel(condition=[>($7, 7)])
TableAccessRel(table=[[CATALOG, SALES, EMP]])
FilterRel(condition=[>($7, 7)])
TableAccessRel(table=[[CATALOG, SALES, EMP]])
More egs in the patch. We can do better than Hive: by pulling up Predicates that are effective above every RelNode and inferring new Predicates for the other side of a Join.
- is duplicated by
-
CALCITE-41 Add rule to propagate constraints onto aliased columns
-
- Closed
-