Dandandan commented on code in PR #8511:
URL: https://github.com/apache/arrow-datafusion/pull/8511#discussion_r1425026593
##########
datafusion/physical-expr/src/aggregate/count.rs:
##########
@@ -198,16 +198,18 @@ fn null_count_for_multiple_cols(values: &[ArrayRef]) ->
usize {
if values.len() > 1 {
let result_bool_buf: Option<BooleanBuffer> = values
.iter()
- .map(|a| a.nulls())
+ .map(|a| a.logical_nulls())
Review Comment:
Yeah @alamb in the end `NullBuffer` has `Arc<Bytes>` so it mostly clones
this + a few `usize`s etc. While not ideal I don't think it will be very
expensive?
https://arrow.apache.org/rust/arrow_buffer/buffer/immutable/struct.Buffer.html
But I like the suggestion of returning a reference or `Cow` in arrow-rs.
--
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]