kumarUjjawal commented on code in PR #24646:
URL: https://github.com/apache/datafusion/pull/24646#discussion_r3852793944
##########
datafusion/functions-aggregate/src/approx_distinct.rs:
##########
@@ -840,6 +840,7 @@ impl AggregateUDFImpl for ApproxDistinct {
| DataType::Map(_, _)
| DataType::Struct(_)
| DataType::Union(_, _)
+ | DataType::Dictionary(_, _)
Review Comment:
Would it work to match on the value type instead, so a dictionary is
supported exactly when its values would be? Something like
`DataType::Dictionary(_, value_type)`
##########
datafusion/functions-aggregate/src/approx_distinct.rs:
##########
@@ -919,6 +920,7 @@ fn is_hll_groups_type(data_type: &DataType) -> bool {
| DataType::Map(_, _)
| DataType::Struct(_)
| DataType::Union(_, _)
+ | DataType::Dictionary(_, _)
Review Comment:
would it make sense to have both dictionary arms on the value type, so
`Dictionary(_, value_type)` is accepted only when
`is_hll_groups_type(value_type)` is true?
--
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]