tustvold commented on code in PR #3558:
URL: https://github.com/apache/arrow-rs/pull/3558#discussion_r1073983917


##########
arrow-select/src/dictionary.rs:
##########
@@ -0,0 +1,171 @@
+use crate::interleave::interleave;
+use arrow_array::builder::BooleanBufferBuilder;
+use arrow_array::cast::{as_generic_binary_array, as_largestring_array, 
as_string_array};
+use arrow_array::types::{ArrowDictionaryKeyType, ByteArrayType};
+use arrow_array::{Array, ArrayRef, DictionaryArray, GenericByteArray};
+use arrow_buffer::{ArrowNativeType, Buffer, MutableBuffer};
+use arrow_data::bit_iterator::BitIndexIterator;
+use arrow_schema::{ArrowError, DataType};
+use std::collections::hash_map::Entry;
+use std::collections::HashMap;
+
+/// Given an array of dictionaries and an optional row mask compute a values 
array
+/// containing all unique, reference values, along with mappings from the 
[`DictionaryArray`]
+/// keys to the new keys within this values array
+pub fn merge_dictionaries<K: ArrowDictionaryKeyType>(
+    dictionaries: &[(&DictionaryArray<K>, Option<&[u8]>)],

Review Comment:
   I plan to use the masks for the interleave kernel



-- 
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]

Reply via email to