houqp commented on issue #670:
URL: 
https://github.com/apache/arrow-datafusion/issues/670#issuecomment-873638959


   I think this might have something to do with our projection push down logic:
   
   ```
   > SELECT
     t1.c9 x, t1.c1 c1
   FROM test t1
   INNER JOIN test t2
   ON t1.c9 = t2.c9
   ORDER BY x;
   [datafusion/src/execution/dataframe_impl.rs:148] &plan = Sort: #x ASC NULLS 
FIRST
     Projection: #t1.c9 AS x, #t1.c1 AS c1
       Join: #t1.c9 = #t2.c9
         TableScan: t1 projection=Some([0, 1])
         TableScan: t2 projection=Some([0, 1])
   ```
   
   Noticed `c1` got pushed down to `t2` table scan as well even though it's not 
being projected. Most likely the projection push down logic is not 
distinguishing between column names and aliases.


-- 
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]


Reply via email to