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

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

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

    https://github.com/apache/flink/pull/2976#discussion_r94964350
  
    --- Diff: 
flink-libraries/flink-table/src/main/scala/org/apache/flink/table/runtime/aggregate/AggregateReduceGroupFunction.scala
 ---
    @@ -87,6 +90,17 @@ class AggregateReduceGroupFunction(
             output.setField(after, 
aggregates(previous).evaluate(aggregateBuffer))
         }
     
    +    // Evaluate grouping sets additional values
    +    if (groupingSetsMapping != null && groupingSetsMapping.nonEmpty) {
    +
    +      val groupingFields = groupKeysMapping.map(_._1)
    +      groupingSetsMapping.map {
    --- End diff --
    
    I would simplify these lines to one map instead of a map followed by 
foreach.


> Add CUBE/ROLLUP/GROUPING SETS operator in SQL
> ---------------------------------------------
>
>                 Key: FLINK-5303
>                 URL: https://issues.apache.org/jira/browse/FLINK-5303
>             Project: Flink
>          Issue Type: New Feature
>          Components: Documentation, Table API & SQL
>            Reporter: Alexander Chermenin
>            Assignee: Alexander Chermenin
>
> Add support for such operators as CUBE, ROLLUP and GROUPING SETS in SQL.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to