Skip to content

Comments

Add Boolean predicate pushdown support (cherry-pick)#7

Open
LLDay wants to merge 1 commit intodf-42-release-bindingfrom
dsemenov/fix/bool-filter
Open

Add Boolean predicate pushdown support (cherry-pick)#7
LLDay wants to merge 1 commit intodf-42-release-bindingfrom
dsemenov/fix/bool-filter

Conversation

@LLDay
Copy link

@LLDay LLDay commented Feb 16, 2026

This is a cheery pick of a commit that fixes a problem with boolean predicates.
See pull request 2082 in apache/iceberg for more details.

This commit adds comprehensive support for pushing down Boolean
predicates to the Iceberg table scan layer, improving query performance
by filtering data at the storage level.

Changes:
- Enhanced expr_to_predicate.rs to handle boolean column expressions:
* Bare boolean columns in filters (e.g., WHERE is_active) are converted
to column = true predicates
* NOT of boolean columns (e.g., WHERE NOT is_active) are converted to
column = false predicates
  * Added Boolean scalar value to Datum conversion
with:
  * Tests for is_active = true/false with EXPLAIN verification
  * Tests for is_active != true with EXPLAIN verification
  * Tests for combined predicates (AND/OR)
  * Tests for IS NULL/IS NOT NULL on boolean columns
- Created test_boolean_table in engine setup for testing
- Updated test schedule and show_tables baseline

All tests verify that predicates are successfully pushed down to
IcebergTableScan, not just executed in FilterExec.

---------

Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants