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

   ### Is your feature request related to a problem or challenge?
   
   `ordering_satisfy_concrete()` function first checks whether the required 
PhysicalSortExpr's length is greater than provided PhysicalSortExpr's length. 
If so, it directly returns false. However, there may be cases such as:
   
   Provided: (a)
   Required: (a,b) ,but a and b are in an equivalent class. 
   
   In that case, an unnecessary sort is added. We can remove it by changing the 
implementation of `ordering_satisfy_concrete()`.
   
   ### Describe the solution you'd like
   
   Required PhysicalSortExpr's are normalized, and then they are simplified 
such that if a normalized expression exists twice or more in the list, the 
later occurrences are removed. After that, we get a normalized list having 
unique elements. Provided PhysicalSortExpr's are also normalized before the 
comparison of expressions.
   
   ### Describe alternatives you've considered
   
   _No response_
   
   ### Additional context
   
   _No response_


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