You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Whilst perusing the code I noticed that GenericBinaryArray::from_list and GenericBinaryArray::from_list have the following logic
let mut builder = ArrayData::builder(Self::get_data_type())
.len(v.len())
.add_buffer(v.data_ref().buffers()[0].clone())
.add_buffer(v.data_ref().child_data()[0].buffers()[0].clone());
if let Some(bitmap) = v.data_ref().null_bitmap() {
builder = builder.null_bit_buffer(bitmap.bits.clone())
}
let data = unsafe { builder.build_unchecked() };
This does not propagate any offset that might be present in the source data
To Reproduce
I suspect if you slice an ArrayList and then pass it to this method, you will lose the offset position.
Expected behavior
The offset, and probably the null count, should be preserved by both methods
The text was updated successfully, but these errors were encountered:
Describe the bug
Whilst perusing the code I noticed that
GenericBinaryArray::from_list
andGenericBinaryArray::from_list
have the following logicThis does not propagate any offset that might be present in the source data
To Reproduce
I suspect if you slice an ArrayList and then pass it to this method, you will lose the offset position.
Expected behavior
The offset, and probably the null count, should be preserved by both methods
The text was updated successfully, but these errors were encountered: