sunjincheng121 commented on a change in pull request #8359: 
[FLINK-11051][table] Add streaming window FlatAggregate to Table API
URL: https://github.com/apache/flink/pull/8359#discussion_r282715818
 
 

 ##########
 File path: 
flink-table/flink-table-api-java/src/main/java/org/apache/flink/table/api/WindowGroupedTable.java
 ##########
 @@ -54,4 +54,39 @@
         * </pre>
         */
        Table select(Expression... fields);
+
+       /**
+        * Performs a flatAggregate operation on a window grouped table. 
FlatAggregate takes a
+        * TableAggregateFunction which returns multiple rows. Use a selection 
after flatAggregate.
+        *
+        * <p>Example:
+        *
+        * <pre>
+        * {@code
+        *   TableAggregateFunction tableAggFunc = new MyTableAggregateFunction
+        *   tableEnv.registerFunction("tableAggFunc", tableAggFunc);
+        *   windowGroupedTable
+        *     .flatAggregate("tableAggFunc(a, b) as (x, y, z)")
+        *     .select("key, window.start, x, y, z")
+        * }
+        * </pre>
+        */
+       FlatAggregateTable flatAggregate(String tableAggregateFunction);
 
 Review comment:
   One more comment, we should make the change: `Similar to an SQL SELECT` -> 
`Similar to a SQL SELECT` in `FlatAggregateTable` JavaDoc as well.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to