adriangb commented on code in PR #19136:
URL: https://github.com/apache/datafusion/pull/19136#discussion_r2616350269
##########
datafusion/datasource-parquet/src/opener.rs:
##########
@@ -176,6 +187,17 @@ impl FileOpener for ParquetOpener {
// We'll also check this after every record batch we read,
// and if at some point we are able to prove we can prune the file
using just the file level statistics
// we can end the stream early.
+ if !constant_columns.is_empty() {
+ predicate = predicate
+ .map(|expr| {
+ if is_dynamic_physical_expr(&expr) {
Review Comment:
Makes sense! I guess there's an opportunity to always apply another rewrite
/ simplify / replace lits pass after snapshotting the physical expression, but
I don't know the reward / risk there (it could be expensive to do it after
every record batch emitted, etc.). So will leave alone for now as you had
originally.
--
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]