akoshchiy commented on code in PR #16790: URL: https://github.com/apache/datafusion/pull/16790#discussion_r2210860376
########## datafusion/sqllogictest/test_files/push_down_filter.slt: ########## @@ -128,12 +128,31 @@ physical_plan 06)----------ProjectionExec: expr=[column1@0 as column1, column2@1 as __unnest_placeholder(d.column2)] 07)------------DataSourceExec: partitions=1, partition_sizes=[1] +statement ok +drop table d; +statement ok +CREATE TABLE d AS VALUES (named_struct('a', 1, 'b', 2)), (named_struct('a', 3, 'b', 4)), (named_struct('a', 5, 'b', 6)); + +query II +select * from (select unnest(column1) from d) where "__unnest_placeholder(d.column1).b" > 5; Review Comment: As I can see, it's a result of struct unnest preprocessing in `SqlToRel::try_process_unnest`. `unnest(struct_col)` will be transformed into `__unnest_placeholder(struct_col).field1, unnest(struct_col).field2` etc. To be honest, I'm not sure, that it was supposed to be like that or not. -- 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