Details
-
Improvement
-
Status: Closed
-
Minor
-
Resolution: Invalid
-
None
-
None
-
None
Description
I have a sql Query :
select a.addr, b.src from a inner join b on a.cust_id=b.cust_id where b.cust_id=1
I convert the query to SqlNode than optimize RelNode:
LogicalProject(addr=[$0], src=[$24])
LogicalJoin(condition=[=($17, $47)], joinType=[inner])
LogicalFilter(condition=[=($17, 1)])
JdbcTableScan(table=[[, a]])
LogicalFilter(condition=[=($26, 1)])
JdbcTableScan(table=[[, b]])
It is ok.Calcite provide me a optimized query...
but i have another table c with fields addr,src as in table a and b.
I want to rewrite the query:
select c.addr,c.src from c where c.cust_id=1
Is possible ?