Re: [PROPOSAL] Materialized view 2.0

2020-04-17 Thread ling miao
If we want to support the expr of key, the different load plan will be need between base and rollup. The key of rollup needs to be transformed by the to_mouth function before the storage engine aggregate the value column. >From the perspective of demand, users only need to be able to store day, mo

Re: Re: [PROPOSAL] Materialized view 2.0

2020-04-17 Thread ling miao
If expressions are supported, the storage engine will changed when the function column is built automatically. Also the mv selector need a expression calculation tool to judge whether mv could be selected for query. After Doris support the count_distinct and count, I will consider this feature. 陈

Re:Re: [PROPOSAL] Materialized view 2.0

2020-04-16 Thread 陈明雨
That could be good. However, if expressions are supported, the function of automatically selecting rollup may fail. Because the reason why Doris can automatically select the rollup is based on keeping the column values consistent. When the column value generates a new value through the expressi

Re: [PROPOSAL] Materialized view 2.0

2020-04-16 Thread Zhao Chun
Hi Ling Very glad to see this proposal. We can discuss whether to support expression operations. For the case that expressions are applied on the KEY column. For example we can easily get a monthly table through a rollup which is defined by "group by to_month(day_column)". For the case that exp

[PROPOSAL] Materialized view 2.0

2020-04-16 Thread ling miao
Hi everyone, *The status of materialized view 1.0* In the present, we have supported the materialized views in Doris 0.12 version. The materialized view selector supports to select the most efficient mv and rewrite the SQL to query against the selected mv instead of the base table. For query resul