You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "godfrey he (JIRA)" <ji...@apache.org> on 2019/04/12 09:39:00 UTC

[jira] [Created] (FLINK-12170) Add support for generating optimized logical plan for Over aggregate

godfrey he created FLINK-12170:
----------------------------------

             Summary: Add support for generating optimized logical plan for Over aggregate
                 Key: FLINK-12170
                 URL: https://issues.apache.org/jira/browse/FLINK-12170
             Project: Flink
          Issue Type: New Feature
          Components: Table SQL / Planner
            Reporter: godfrey he
            Assignee: godfrey he


This issue aims to generate optimized plan for Over aggregate queries, e.g. 
{code:sql}
SELECT a, b, c, RANK() OVER (PARTITION BY b ORDER BY c) FROM MyTable
{code}

currently, Stream requires all over aggregate functions must be computed on the  same window, e.g. 
{code:sql}
SELECT c,
    COUNT(a) OVER (PARTITION BY c ORDER BY proctime RANGE UNBOUNDED PRECEDING),
    SUM(a) OVER (PARTITION BY b ORDER BY proctime RANGE UNBOUNDED PRECEDING)
from MyTable
{code} 
the above sql is not supported because the partition keys is different.

Batch does not  have such limitation.






--
This message was sent by Atlassian JIRA
(v7.6.3#76005)