mingmwang commented on code in PR #5837:
URL: https://github.com/apache/arrow-datafusion/pull/5837#discussion_r1159221512


##########
datafusion/core/src/physical_plan/aggregates/mod.rs:
##########
@@ -360,7 +380,9 @@ impl ExecutionPlan for AggregateExec {
 
     fn required_input_distribution(&self) -> Vec<Distribution> {
         match &self.mode {
-            AggregateMode::Partial => 
vec![Distribution::UnspecifiedDistribution],
+            AggregateMode::Partial | AggregateMode::Single => {

Review Comment:
   It should be the same as the `AggregateMode::Partial`.  And this new rule 
will be applied after the `EnforceDistribution` rule,  which means the 
distribution requirements are already satisfied, and then the adjacent 
`Partial` and `Final` Aggregate are combined to a new `Single` Aggregate.



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

Reply via email to