Xuanwo opened a new pull request, #24801:
URL: https://github.com/apache/datafusion/pull/24801

   ## Which issue does this PR close?
   
   - Part of #318.
   - Umbrella PR: #23738.
   - Depends on #23829.
   
   ## Rationale for this change
   
   An ASOF join emits each left row exactly once and does not change left-side
   values. A deterministic predicate that references only the left input can
   therefore run before matching. Right-only and mixed predicates must remain
   above the join because unmatched right fields are NULL-padded, and volatile
   predicates must keep their original evaluation point.
   
   Pushing the safe subset reduces the number of rows entering the ASOF join
   without changing query results.
   
   ## What changes are included in this PR?
   
   - Push deterministic left-only conjuncts below logical ASOF joins.
   - Keep right-only, mixed, and volatile predicates above the join.
   - Document the cardinality and NULL-padding assumptions at the optimizer 
rule.
   - Add focused optimizer snapshots for all four predicate categories.
   
   ## Are these changes tested?
   
   - `cargo fmt --all`
   - `cargo clippy --all-targets --all-features -- -D warnings`
   - `cargo test --profile ci -p datafusion-optimizer asof_join_ --all-features`
   - The extended workspace test command from the contributor guide
   
   ## Are there any user-facing changes?
   
   No result semantics or public APIs change. Eligible ASOF joins may execute 
with
   fewer left-side rows after logical optimization.
   


-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to