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-8650) Add tests and documentation for WINDOW clause
Date Fri, 29 Jun 2018 16:10:00 GMT

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

ASF GitHub Bot commented on FLINK-8650:
---------------------------------------

Github user fhueske commented on a diff in the pull request:

    https://github.com/apache/flink/pull/6226#discussion_r199209179
  
    --- Diff: flink-libraries/flink-table/src/test/scala/org/apache/flink/table/api/stream/sql/OverWindowTest.scala
---
    @@ -44,7 +44,26 @@ class OverWindowTest extends TableTestBase {
           "sum(DISTINCT c) OVER (PARTITION BY b ORDER BY proctime ROWS BETWEEN 2 preceding
AND " +
           "CURRENT ROW) as sum2 " +
           "from MyTable"
    -
    +    val sql2 = "SELECT " +
    --- End diff --
    
    I think we can reduce the number of tests is a bit. 
    We are basically testing Calcite's parser / validator multiple times with very similar
queries. For example, Calcite does not distinguish between proctime and rowtime. One query
with a `WINDOW` clause per test case should be sufficient.


> Add tests and documentation for WINDOW clause
> ---------------------------------------------
>
>                 Key: FLINK-8650
>                 URL: https://issues.apache.org/jira/browse/FLINK-8650
>             Project: Flink
>          Issue Type: Improvement
>          Components: Table API &amp; SQL
>            Reporter: Timo Walther
>            Assignee: Sergey Nuyanzin
>            Priority: Major
>              Labels: pull-request-available
>
> We support queries with a {{WINDOW}} clause like:
> {code}
> SELECT a, SUM(c) OVER w, MIN(c) OVER w FROM MyTable WINDOW w AS (PARTITION BY a ORDER
BY proctime ROWS BETWEEN 4 PRECEDING AND CURRENT ROW)
> {code}
> But this is neither documented nor tested.



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

Mime
View raw message