jayzhan211 commented on PR #15057: URL: https://github.com/apache/datafusion/pull/15057#issuecomment-2801563360
> Is this the right API, or should some of the information on how to optimize / adapt to a specific file schema live in PhysicalExpr::with_file_schema or something like that? rewrite with file schema is specialized to filter, if you add `PhysicalExpr::with_file_schema` that means you may expect other kind of rewrite for other `PhysicalExpr`, I don't think we need this so far. > Can we use this mechanism both for variant_get(col, 'key') -> col.typed_value.key as well as cast(a, i64) = 100 -> cast(cast(a,i32),i64) = 100 -> a = 100 or is that mixing too many things into the same API? Makes sense to me if we have many rules inside the `filter_rewrite_with_file_schema` logic as long as the rewrite is leveraged on the provided file schema. -- 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: github-unsubscr...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org