Re: Is it possible to retrieve materialized view query rewrite from Calcite Plan

2019-09-15 Thread Danny Chan
Hi, Shubham Kumar ~ > However, I wanted the optimized rewrite SQL query if possible, not just the > plan. So far, I tried to use the rel2sql api but when I print > RelNode.toString(), it gives me a plan which involves scanning the raw > tables and hence the SQL generated by rel2sql is not the one

Re: How does Calcite implement `Column Prune`?

2019-09-15 Thread Chunwei Lei
Hi, Ham and Stamatis. In our use case, we use transformation rules like ProjectXXXTransposeRule to do column pruning. For example, if we have a sql: select a from t where b > 10; the logical plan is LogcaiProject(a) LogicalFilter(b>10) LogcicalTableScan(a,b,c) then we

Re: [DISCUSS] Release apache-calcite-1.21.0 (release candidate 1)

2019-09-15 Thread Danny Chan
Nice summary of the release problems, Stamatis ! Maybe we should put the precautions to the website so that other RM can follow in the next releases ~ Best, Danny Chan 在 2019年9月12日 +0800 AM7:54,Stamatis Zampetakis ,写道: > The release process for apache-calcite-1.21.0 is now complete. > > You can

[jira] [Created] (CALCITE-3348) AssertionError while determining distribution of Calc

2019-09-15 Thread Wang Yanlin (Jira)
Wang Yanlin created CALCITE-3348: Summary: AssertionError while determining distribution of Calc Key: CALCITE-3348 URL: https://issues.apache.org/jira/browse/CALCITE-3348 Project: Calcite

Re: How does Calcite implement `Column Prune`?

2019-09-15 Thread Danny Chan
Hi, Han Mingcong ~ I guess the topic you touched is the “project push down”. One way is like Stamatis said, use the RelFieldTrimmer which belong to the sql-to-rel conversion phrase now, the default value is “false”, you can open it through the [1]. Another way is like Chunwei said, you can