[jira] [Created] (FLINK-6839) Improve SQL OVER alias When only one OVER window agg in selection.

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[jira] [Created] (FLINK-6839) Improve SQL OVER alias When only one OVER window agg in selection.

JIRA jira@apache.org
sunjincheng created FLINK-6839:
----------------------------------

             Summary: Improve SQL OVER alias When only one OVER window agg in selection.
                 Key: FLINK-6839
                 URL: https://issues.apache.org/jira/browse/FLINK-6839
             Project: Flink
          Issue Type: Improvement
            Reporter: sunjincheng


For OVER SQL:
{code}
SELECT a COUNT(c) OVER (ORDER BY proctime  RANGE BETWEEN INTERVAL '10' SECOND PRECEDING AND CURRENT ROW) as cnt1 FROM MyTable
{code}

We expect plan {{DataStreamCalc(select=[a, w0$o0 AS cnt1]) But we get {{DataStreamCalc(select=[a, w0$o0 AS $1]) }}. this improve only for plan check.  the functional is work well in nested queries´╝îe.g.:
{code}
SELECT cnt1 from (SELECT a COUNT(c) OVER (ORDER BY proctime  RANGE BETWEEN INTERVAL '10' SECOND PRECEDING AND CURRENT ROW) as cnt1 FROM MyTable)
{code}
The SQL above is work well. which mentioned in [FLINK-6760|https://issues.apache.org/jira/browse/FLINK-6760].



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
Loading...