mingmwang commented on PR #4185:
URL: 
https://github.com/apache/arrow-datafusion/pull/4185#issuecomment-1312759047

   > There is an important point about `Schema` need to discuss.
   > 
   > We can change `Schema` into `set` instead of `list`. Because it would 
cause many projection just for order of field.
   > 
   > such as
   > 
   > ```
   > a b -> proj(join(b a))
   > a b c ->  join(proj(join(b a)) c) -> project(join(c, project (join(b a))))
   > ```
   > 
   > Lots of projection will make our rule become complex, we should consider 
many case, especially for join reorder.
   > 
   > A simple but efficient way is override `==`
   
   I think it is because you make the rule run a bottom-up process, then lots 
of projections are added. If we make it a top-down
   process, only a final project will be added.


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