Rich-T-kid commented on code in PR #12059:
URL: https://github.com/apache/arrow-rs/pull/12059#discussion_r4662385781
##########
arrow-select/src/interleave.rs:
##########
@@ -264,33 +264,72 @@ fn interleave_dictionaries<K: ArrowDictionaryKeyType>(
let dictionaries: Vec<_> = arrays.iter().map(|x|
x.as_dictionary::<K>()).collect();
let (should_merge, has_overflow) =
should_merge_dictionary_values::<K>(&dictionaries, indices.len());
- if !should_merge {
- return if has_overflow {
- interleave_fallback(arrays, indices)
+ let strategy = if should_merge {
+ DictionaryInterleaveStrategy::MergeDictionaries
+ } else {
+ let first_values = dictionaries[0].values();
+ if dictionaries
+ .iter()
+ .skip(1)
+ .all(|dictionary| Arc::ptr_eq(first_values, dictionary.values()))
+ {
Review Comment:
yea this is fine, ill update the pr description
--
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]