Github user fhueske commented on a diff in the pull request: https://github.com/apache/flink/pull/3851#discussion_r116444166 --- Diff: flink-libraries/flink-table/src/test/scala/org/apache/flink/table/api/scala/stream/sql/WindowAggregateTest.scala --- @@ -31,6 +31,18 @@ class WindowAggregateTest extends TableTestBase { streamUtil.addTable[(Int, String, Long)]( "MyTable", 'a, 'b, 'c, 'proctime.proctime, 'rowtime.rowtime) + /** + * OVER clause is necessary for [[OverAgg0]] window function. + */ + @Test(expected = classOf[ValidationException]) + def testOverAggregation() = { + streamUtil.addFunction("overAgg", new OverAgg0) + + val sqlQuery = "SELECT overAgg(c, a) FROM MyTable" + + streamUtil.verifySql(sqlQuery, "n/a") --- End diff -- `streamUtil.tEnv.sql(sqlQuery)` is sufficient. We do not need to call the optimizer.
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---