waynexia opened a new issue, #3914:
URL: https://github.com/apache/arrow-datafusion/issues/3914

   **Is your feature request related to a problem or challenge? Please describe 
what you are trying to do.**
   The plan used to (before #3841) be like
   
   
https://github.com/apache/arrow-datafusion/blob/a9ee67471d1ab0ad11f12d024315b3a824d6101f/benchmarks/expected-plans/q21.txt#L15
   
   Which contains some duplicate exprs, see the [file 
diff](https://github.com/apache/arrow-datafusion/commit/431a4127f5e590dba2c87d109f9702b369ba8ea2#diff-a46012c0133b3e64d2ba18a3ac11f02eb5110c5a960be481f5773737a2b15e5b)
 for highlights.
   
   And in #3841 @Dandandan run some optimize rules one more time and got the 
duplicate exprs optimized out. But in #3861 the duplicate exprs will cause 
another problem when combine with `CommonSubexpressionEliminate` rule.
    
   **Describe the solution you'd like**
   
   Besides let other rules to do further optimization (this is useful to make 
more optimizations), I think it's also important to generate a "good enough" 
plan from a rule itself (i.e., remove duplications like this in 
`FilterPushdown`). So we can cut the dependent graph among individual plans 
(which is hard to maintain...).
   
   **Describe alternatives you've considered**
   A clear and concise description of any alternative solutions or features 
you've considered.
   
   **Additional context**
   Add any other context or screenshots about the feature request here.
   


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