Skip to content

Conversation

yhuang-db
Copy link
Contributor

What changes were proposed in this pull request?

This PR proposes to add a utility class to enable the evaluation of an InternalRow using a DSv2 predicate. In particular, it includes

  • converting dsv2 predicates to catalyst expressions
  • converting dsv2 expression to catalyst expressions
    • NamedReference -> BoundReference
    • LiteralValue -> catalyst Literal
  • Creating InterpretedPredicate and evaluate internalRow

Why are the changes needed?

This would be helpful for partition pruning, where the runtime filters are DSv2 predicates and the partitionValue are internalRows (for partitionFiles in Spark). In this way, partitionFiles can be pruned directly with DSv2 predicates at the scan level.

Does this PR introduce any user-facing change?

No

How was this patch tested?

New unit tests.

Was this patch authored or co-authored using generative AI tooling?

No

@github-actions github-actions bot added the SQL label Oct 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant