Commit 1b8b212
# Which issue does this PR close?
- Closes #8752.
# Rationale for this change
The algorithms suggested in this PR originate from the `case` logic in
DataFusion (see
[datafusion#18152](apache/datafusion#18152) and
[datafusion#18444](apache/datafusion#18444)). I
think it might be useful to move them to `arrow-rs` instead of being
tucked away in a corner of the DataFusion codebase.
# What changes are included in this PR?
Adds a two-way and n-way merge algorithm that's halfway between `zip`
and `interleave`. In contrast to `zip` the truthy and falsy arrays do
not need to be prealigned. In contrast to `interleave` the relative
order of elements in each input array is retained in the final result.
# Are these changes tested?
I've already added two minimal unit tests, more should probably be
added.
# Are there any user-facing changes?
No breaking API changes
---------
Co-authored-by: Andrew Lamb <[email protected]>
1 parent 5ee07d1 commit 1b8b212
File tree
6 files changed
+904
-2
lines changed- arrow-select/src
- arrow
- benches
- src/compute
6 files changed
+904
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| 32 | + | |
32 | 33 | | |
33 | 34 | | |
34 | 35 | | |
| |||
0 commit comments