Rich-T-kid commented on code in PR #23187:
URL: https://github.com/apache/datafusion/pull/23187#discussion_r3503412182
##########
datafusion/physical-plan/src/aggregates/group_values/multi_group_by/mod.rs:
##########
@@ -1067,6 +1067,42 @@ fn make_group_column(field: &Field) -> Result<Box<dyn
GroupColumn>> {
v.push(Box::new(BooleanGroupValueBuilder::<false>::new()));
}
}
+ DataType::Dictionary(key_dt, value_dt) => {
+ let new_field = Field::new("", *value_dt.clone(), true);
+ let inner = make_group_column(&new_field)?;
+ let col: Box<dyn GroupColumn> = match key_dt.as_ref() {
+ DataType::Int8 =>
Box::new(dictionary::DictionaryGroupValuesColumn::<
+ Int8Type,
+ >::new(inner, &new_field)),
+ DataType::Int16 =>
Box::new(dictionary::DictionaryGroupValuesColumn::<
+ Int16Type,
+ >::new(inner, &new_field)),
+ DataType::Int32 =>
Box::new(dictionary::DictionaryGroupValuesColumn::<
+ Int32Type,
+ >::new(inner, &new_field)),
+ DataType::Int64 =>
Box::new(dictionary::DictionaryGroupValuesColumn::<
+ Int64Type,
+ >::new(inner, &new_field)),
+ DataType::UInt8 =>
Box::new(dictionary::DictionaryGroupValuesColumn::<
+ UInt8Type,
+ >::new(inner, &new_field)),
+ DataType::UInt16 =>
Box::new(dictionary::DictionaryGroupValuesColumn::<
+ UInt16Type,
+ >::new(inner, &new_field)),
+ DataType::UInt32 =>
Box::new(dictionary::DictionaryGroupValuesColumn::<
+ UInt32Type,
+ >::new(inner, &new_field)),
+ DataType::UInt64 =>
Box::new(dictionary::DictionaryGroupValuesColumn::<
+ UInt64Type,
+ >::new(inner, &new_field)),
+ _ => {
+ return not_impl_err!(
Review Comment:
Might be worth changing this to `unreachable!`
--
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]