Skip to content

Conversation

@Mark1626
Copy link

Closes #18922

…e present

Signed-off-by: Nimalan <nimalan.m@protonmail.com>
@github-actions github-actions bot added the common Related to common crate label Nov 25, 2025
Copy link
Contributor

@dqkqd dqkqd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @Mark1626. This change makes sense to me.


let values = HashSet::from([ScalarValue::from(1i32), ScalarValue::from(3i32)]);
let contained_a = partition_stats.contained(&column_a, &values).unwrap();
let expected_contained_a = BooleanArray::from(vec![true, true]);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The stats:

a b
1 2
3 4

Running contained on a with values = [1, 3] returns [true, true].

I wonder if we need some cases that return false, or None as well.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The earlier case covers false. I've added a test cases for the null scenario, changed the or to a or_kleene so it works for null

Copy link
Contributor

@adriangb adriangb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

common Related to common crate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Incorrectly result from PartitionPruningStatistics when multiple values are present

3 participants