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-7776) do not emit duplicated records in group aggregation
Date Mon, 09 Oct 2017 08:23:00 GMT

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

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

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

    https://github.com/apache/flink/pull/4785#discussion_r143405406
  
    --- Diff: flink-libraries/flink-table/src/main/scala/org/apache/flink/table/runtime/aggregate/GroupAggProcessFunction.scala
---
    @@ -129,17 +129,19 @@ class GroupAggProcessFunction(
           state.update(accumulators)
           cntState.update(inputCnt)
     
    -      // if this was not the first row and we have to emit retractions
    -      if (generateRetraction && !firstRow) {
    +      // if this was not the first row and we may have to emit retractions
    --- End diff --
    
    I'd remove the `"and we may have to emit retractions"` part of the comment as this is
not reflected by the condition.


> do not emit duplicated records in group aggregation
> ---------------------------------------------------
>
>                 Key: FLINK-7776
>                 URL: https://issues.apache.org/jira/browse/FLINK-7776
>             Project: Flink
>          Issue Type: Improvement
>          Components: Table API & SQL
>            Reporter: Ruidong Li
>            Assignee: Ruidong Li
>
> the current group aggregation will compare the last {{Row}} and current {{Row}} when
{{generateRetraction}} is {{true}} and {{firstRow}} is {{false}} in {{GroupAggProcessFunction}},
> this logic should be applied to all cases when {{firstRow}} is false, if current {{Row}}
is same with previous {{Row}}, we do not emit any records.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message