You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2022/02/17 15:13:20 UTC

[GitHub] [arrow-datafusion] alex-natzka opened a new pull request #1855: Fix incorrect aggregation incorrect in case that GROUP BY contains duplicate column names

alex-natzka opened a new pull request #1855:
URL: https://github.com/apache/arrow-datafusion/pull/1855


   # Which issue does this PR close?
   
   <!--
   We generally require a GitHub issue to be filed for all bug fixes and enhancements and this helps us generate change logs for our releases. You can link an issue to this PR using the GitHub syntax. For example `Closes #123` indicates that this PR will close issue #123.
   -->
   
   Closes #1854 .
   
   # What changes are included in this PR?
   <!--
   There is no need to duplicate the description in the issue here but it is sometimes worth providing a summary of the individual changes in this PR.
   -->
   * Add `HashAggregateExec::output_group_expr` that provides the GROUP BY columns with indices that correctly correspond to the schema of the `RecordBatchStream` created by this `ExecutionPlan`.
   * Use `HashAggregateExec::output_group_expr` in `DefaultPhysicalPlanner` when planning a `LogicalPlan::Aggregate`. (The latter is planned as two `HashAggregateExec`s and the second one needs to correctly use the output columns of the first as input.)
   * Add test `csv_query_sum_crossjoin` to `datafusion/tests/sql/aggregates.rs` that checks against regressions from the correct behavior.
   
   # Are there any user-facing changes?
   <!--
   If there are user-facing changes then we may require documentation to be updated before approving the PR.
   -->
   The added `HashAggregateExec::output_group_expr` is marked as `pub`. As this is only an addition, it does not break any existing public API. (The added function could also be marked `pub(crate)` or `pub(super)`, but this did not seem in line with the rest of the methods that `HashAggregateExec` exposes.)
   
   <!--
   If there are any breaking changes to public APIs, please add the `api change` label.
   -->
   


-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow-datafusion] alex-natzka commented on pull request #1855: Fix incorrect aggregation in case that GROUP BY contains duplicate column names

Posted by GitBox <gi...@apache.org>.
alex-natzka commented on pull request #1855:
URL: https://github.com/apache/arrow-datafusion/pull/1855#issuecomment-1046615300


   > @alex-natzka looks like there is a minor linter formatting error that needs to be addressed.
   
   Woops, that's right. Apparently the formatting was off in `hash_aggregate.rs`. Ran `cargo fmt`, this should do the trick.


-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow-datafusion] Jimexist merged pull request #1855: Fix incorrect aggregation in case that GROUP BY contains duplicate column names

Posted by GitBox <gi...@apache.org>.
Jimexist merged pull request #1855:
URL: https://github.com/apache/arrow-datafusion/pull/1855


   


-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow-datafusion] houqp commented on pull request #1855: Fix incorrect aggregation in case that GROUP BY contains duplicate column names

Posted by GitBox <gi...@apache.org>.
houqp commented on pull request #1855:
URL: https://github.com/apache/arrow-datafusion/pull/1855#issuecomment-1046573039


   @alex-natzka looks like there is a minor linter formatting error that needs to be addressed.


-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow-datafusion] alex-natzka commented on pull request #1855: Fix incorrect aggregation in case that GROUP BY contains duplicate column names

Posted by GitBox <gi...@apache.org>.
alex-natzka commented on pull request #1855:
URL: https://github.com/apache/arrow-datafusion/pull/1855#issuecomment-1046678151


   @houqp I force-pushed the branch again with corrected formatting. Could you re-approve the workflows when it's convenient for you?


-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow-datafusion] alamb commented on pull request #1855: Fix incorrect aggregation in case that GROUP BY contains duplicate column names

Posted by GitBox <gi...@apache.org>.
alamb commented on pull request #1855:
URL: https://github.com/apache/arrow-datafusion/pull/1855#issuecomment-1053679030


   Thanks @alex-natzka 


-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org