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

   ## Which issue does this PR close?
   
   Related to #25620. Split from #25648 following [the review 
request](https://github.com/apache/datafusion/pull/25648#discussion_r4122769097).
 This PR can be reviewed and merged independently.
   
   ## Rationale for this change
   
   An equality filter can narrow a column's bounds to one value without proving 
that any row contains that value. With input bounds [1, 100] and actual values 
1 and 100, `a = 5` returns no rows, but currently reports an exact distinct 
count of one when its estimated row count is positive.
   
   ## What changes are included in this PR?
   
   Report `Inexact(1)` for a singleton domain when the filtered row count is an 
estimate or is unknown. Preserve exact zero for an exactly empty output and 
exact one when an exact positive row count proves that the singleton is present.
   
   Add an execution regression for the absent value and update affected 
unit-test and Parquet EXPLAIN expectations.
   
   ## What is the testing strategy for this PR?
   
   Passed on this independent branch:
   
   - `cargo test --profile ci -p datafusion-physical-plan --lib` (2,364 tests)
   - `cargo clippy --profile ci -p datafusion-physical-plan --all-targets 
--all-features -- -D warnings`
   - `cargo test --profile ci -p datafusion-sqllogictest --test sqllogictests 
-- parquet_statistics.slt`
   - `cargo fmt --all` and `git diff --check`
   
   Benchmarks were not rerun for this split. This extracts the 
singleton-precision implementation already present in #25648.
   
   ## Are there any user-facing changes?
   
   EXPLAIN reports an estimated distinct count when a matching row is not 
proven. No public API changes.
   


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