berkaysynnada commented on PR #15566: URL: https://github.com/apache/datafusion/pull/15566#issuecomment-2809586017
> > @adriangb one point doesn't come to me obvious. I've erased a comment saying that "filter predicates reflect the output schema after applying the projection", and some tests are written based on that. Is that the case really? I'm seeing that in with_projection() API of FilterExec the predicates are kept as they are, so they are not updated according to the projection. What am I missing? > > Yeah I saw that you got rid of `reassign_predicate_columns`. Maybe I misunderstood how it's supposed to work by I thought that if you have a `FilterExec { projection: [1, 0], predicate: Column { name: "b", index: 0 } }` the predicate is referencing the indexes after `FilterExec` does it's projection. So if you want to push that predicate down to children (e.g. to the scan) you need to invert the projection / match the column with the input schema (i.e. `Column { name: "b", index: 1 }`. Okay, there is no problem with my understanding then. I'll implement the projection case as well now -- 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