feiniaofeiafei commented on code in PR #63690:
URL: https://github.com/apache/doris/pull/63690#discussion_r3402024730


##########
fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/eageraggregation/PushDownAggContext.java:
##########
@@ -87,20 +96,22 @@ public PushDownAggContext(List<AggregateFunction> 
aggFunctions,
         this.passThroughBigJoin = passThroughBigJoin;
         this.hasDecomposedAggIf = hasDecomposedAggIf;
         this.hasCaseWhen = hasCaseWhen;
+        this.bilateralState = Objects.requireNonNull(bilateralState);
+        for (Map.Entry<AggregateFunction, Alias> entry : 
this.aliasMap.entrySet()) {
+            AggregateFunction aggFunction = entry.getKey();
+            ExprId id = entry.getValue().getExprId();
+            Optional<Action> hintAction = EagerAggHints.decide(aggFunction);
+            hintAction.ifPresent(action -> bilateralState.putAction(id, 
action));
+        }
+
     }
 
     /**
      * check validation
      * @return true, if groupKeys is not empty and no group by key is in 
aggFunctionsInputSlots
      */
     public boolean isValid() {

Review Comment:
   Fixed. The javadoc changed and add tests for this situation: "no group by 
key is in aggFunctionsInputSlots"



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to