-
Notifications
You must be signed in to change notification settings - Fork 233
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow filtering on newly added columns #246
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some questions, but nothing that I think is blocking, thanks @Fokko !
pyiceberg/expressions/visitors.py
Outdated
if "Not found in file schema" in str(e): | ||
if isinstance(expr, BoundIsNull): | ||
return AlwaysTrue() | ||
else: | ||
return AlwaysFalse() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Curious, why not do this in the visitor itself (_ColumnNameTranslator#visit_bound_predicate)? Is it something we would want decoupled from it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I actually like that more, great suggestion 👍
arrow_table = test_table_add_column.scan(row_filter="b == '2'").to_arrow() | ||
assert arrow_table["b"].to_pylist() == ['2'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As a sanity check should we add a test which validates that a row_filter='b is NOT NULL' returns the same?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a good one, added 👍
* Allow filtering on newly added columns Resolves apache#217 * Thanks Amogh!
Resolves #217