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

   ## Which issue does this PR close?
   
   Closes #25239. Follows up on #21907 and [Arrow 
#6485](https://github.com/apache/arrow-rs/pull/6485).
   
   ## Rationale for this change
   
   An absent Parquet `null_count` is unknown. Treating it as zero can discard 
NULL rows during `NULLS FIRST` TopK and `IS NULL` pruning, and let 
metadata-only `COUNT(column)` return an incorrect result.
   
   ## What changes are included in this PR?
   
   Preserve missing null counts in the shared row-group statistics adapter and 
file statistics. Remove the per-caller compatibility flag so static pruning, 
runtime pruning, and fully matched proofs use the same interpretation.
   
   ## What is the testing strategy for this PR?
   
   Regressions cover missing and explicit-zero counts, static pruning, 
file-statistics precision, `COUNT`, and TopK with ASC/DESC, NULLS FIRST/LAST, 
and dynamic pruning enabled/disabled. The affected cases fail without the fix. 
Extended workspace tests, strict all-target/all-feature Clippy, and the full 
lint suite pass.
   
   ## Are there any user-facing changes?
   
   Correct results for Parquet files with missing null counts. These files, 
including older parquet-rs output, may lose optimizations that require known 
null counts; this also affects `IS NULL` and metadata-only `COUNT`, beyond 
`NULLS FIRST`. Explicit counts retain their existing behavior. 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