comphead commented on code in PR #20143:
URL: https://github.com/apache/datafusion/pull/20143#discussion_r2764647702
##########
datafusion/sqllogictest/test_files/projection_pushdown.slt:
##########
@@ -118,6 +118,24 @@ SELECT id, s['value'] FROM simple_struct ORDER BY id;
4 300
5 250
+query TT
+EXPLAIN SELECT s['label'] FROM simple_struct;
+----
+logical_plan
+01)Projection: get_field(simple_struct.s, Utf8("label"))
+02)--TableScan: simple_struct projection=[s]
+physical_plan DataSourceExec: file_groups={1 group:
[[WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/projection_pushdown/simple.parquet]]},
projection=[get_field(s@1, label) as simple_struct.s[label]], file_type=parquet
Review Comment:
so `projection=[get_field(s@1, label)` means the we extract label field from
`s` structure column as earlier as possible, on the scan level?
##########
datafusion/sqllogictest/test_files/projection_pushdown.slt:
##########
@@ -118,6 +118,24 @@ SELECT id, s['value'] FROM simple_struct ORDER BY id;
4 300
5 250
+query TT
+EXPLAIN SELECT s['label'] FROM simple_struct;
+----
+logical_plan
+01)Projection: get_field(simple_struct.s, Utf8("label"))
+02)--TableScan: simple_struct projection=[s]
+physical_plan DataSourceExec: file_groups={1 group:
[[WORKSPACE_ROOT/datafusion/sqllogictest/test_files/scratch/projection_pushdown/simple.parquet]]},
projection=[get_field(s@1, label) as simple_struct.s[label]], file_type=parquet
Review Comment:
so `projection=[get_field(s@1, label)` means the we extract `label` field
from `s` structure column as earlier as possible, on the scan level?
--
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]