flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (FLINK-5624) Support tumbling window on streaming tables in the SQL API
Date Thu, 02 Feb 2017 22:44:51 GMT

    [ https://issues.apache.org/jira/browse/FLINK-5624?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15850641#comment-15850641

ASF GitHub Bot commented on FLINK-5624:

Github user fhueske commented on the issue:

    Hi @haohui, thanks for your contribution!
    The referenced JIRA is about adding support for group windows to SQL, not OVER (or row)
windows. It should enable queries such as:
    SELECT a, sum(b) as sumB, TUMBLE_END(rowtime(), INTERVAL '1' HOUR) AS t,
      FROM myT
    GROUP BY TUMBLE(rowtime(), INTERVAL '1' HOUR), a;
    I saw that you contributed `TUMBLE` just very recently to Calcite, so this feature is
not yet available in a Calcite release that we could link against. Until then, we could add
support for the more manual version of SQL tumbling windows:
    SELECT a, SUM(b) AS sumB, CEIL(rowtime() TO HOUR) AS t,
      FROM myT
    GROUP BY CEIL(rowtime() TO HOUR), a
    We would also need to find a way to reference the `rowtime`. We do not want to expose
this as an actual attribute in Flink's SQL (internally, Flink treats record timestamps as
metadata which may not be modified by a query). The current approach would be to implement
a built-in function which serves as a marker and is replaced during the translation.
    Best, Fabian

> Support tumbling window on streaming tables in the SQL API
> ----------------------------------------------------------
>                 Key: FLINK-5624
>                 URL: https://issues.apache.org/jira/browse/FLINK-5624
>             Project: Flink
>          Issue Type: Bug
>          Components: Table API & SQL
>            Reporter: Haohui Mai
>            Assignee: Haohui Mai
> This is a follow up of FLINK-4691.
> FLINK-4691 adds supports for group-windows for streaming tables. This jira proposes to
expose the functionality in the SQL layer via the {{GROUP BY}} clauses, as described in http://calcite.apache.org/docs/stream.html#tumbling-windows.

This message was sent by Atlassian JIRA

View raw message