Fix equality of parametrizable ArrayAgg function#17065
Merged
findepi merged 1 commit intoapache:mainfrom Aug 7, 2025
Merged
Conversation
The `ArrayAgg` struct is stateful, therefore it must implement `AggregateUDFImpl::equals` and `hash_value` functions.
This was referenced Aug 7, 2025
alamb
reviewed
Aug 7, 2025
| self.doc() | ||
| } | ||
|
|
||
| udf_equals_hash!(AggregateUDFImpl); |
Contributor
There was a problem hiding this comment.
Should the equal method also check is_input_pre_ordered ?
Member
Author
There was a problem hiding this comment.
I think it should and that it does.
Contributor
There was a problem hiding this comment.
I had to remind myself that this macro calls into the PartialEq method
alamb
approved these changes
Aug 7, 2025
| self.doc() | ||
| } | ||
|
|
||
| udf_equals_hash!(AggregateUDFImpl); |
Contributor
There was a problem hiding this comment.
I had to remind myself that this macro calls into the PartialEq method
Contributor
|
Thanks @findepi |
nuno-faria
pushed a commit
to nuno-faria/datafusion
that referenced
this pull request
Aug 8, 2025
The `ArrayAgg` struct is stateful, therefore it must implement `AggregateUDFImpl::equals` and `hash_value` functions.
LiaCastaneda
pushed a commit
to DataDog/datafusion
that referenced
this pull request
Aug 12, 2025
The `ArrayAgg` struct is stateful, therefore it must implement `AggregateUDFImpl::equals` and `hash_value` functions.
LiaCastaneda
pushed a commit
to DataDog/datafusion
that referenced
this pull request
Aug 12, 2025
The `ArrayAgg` struct is stateful, therefore it must implement `AggregateUDFImpl::equals` and `hash_value` functions.
alamb
added a commit
that referenced
this pull request
Aug 14, 2025
* fix: string_agg not respecting ORDER BY * Fix equality of parametrizable ArrayAgg function (#17065) The `ArrayAgg` struct is stateful, therefore it must implement `AggregateUDFImpl::equals` and `hash_value` functions. * Implement AggregateUDFImpl::equals and AggregateUDFImpl::hash_value for ArrayAgg * Implement alternative fix * Remove 'use std::any::Any' * Add sqllogictest for string_agg plan * Revert as_any to their original implementations --------- Co-authored-by: Piotr Findeisen <[email protected]> Co-authored-by: Andrew Lamb <[email protected]>
LiaCastaneda
pushed a commit
to DataDog/datafusion
that referenced
this pull request
Aug 14, 2025
* fix: string_agg not respecting ORDER BY * Fix equality of parametrizable ArrayAgg function (apache#17065) The `ArrayAgg` struct is stateful, therefore it must implement `AggregateUDFImpl::equals` and `hash_value` functions. * Implement AggregateUDFImpl::equals and AggregateUDFImpl::hash_value for ArrayAgg * Implement alternative fix * Remove 'use std::any::Any' * Add sqllogictest for string_agg plan * Revert as_any to their original implementations --------- Co-authored-by: Piotr Findeisen <[email protected]> Co-authored-by: Andrew Lamb <[email protected]> (cherry picked from commit f05b128)
LiaCastaneda
added a commit
to DataDog/datafusion
that referenced
this pull request
Aug 14, 2025
* fix: string_agg not respecting ORDER BY * Fix equality of parametrizable ArrayAgg function (apache#17065) The `ArrayAgg` struct is stateful, therefore it must implement `AggregateUDFImpl::equals` and `hash_value` functions. * Implement AggregateUDFImpl::equals and AggregateUDFImpl::hash_value for ArrayAgg * Implement alternative fix * Remove 'use std::any::Any' * Add sqllogictest for string_agg plan * Revert as_any to their original implementations --------- (cherry picked from commit f05b128) Co-authored-by: Nuno Faria <[email protected]> Co-authored-by: Piotr Findeisen <[email protected]> Co-authored-by: Andrew Lamb <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
ArrayAggstruct is stateful, therefore it must implementAggregateUDFImpl::equalsandhash_valuefunctions.