amaliujia commented on PR #37750:
URL: https://github.com/apache/spark/pull/37750#issuecomment-1258518169

   Because Spark supports `SELECT distinct(col1, col2)` (and the return is a 
struct of co1 and col2), which makes this error message proposal complicated. 
   
   Because now we cannot say that `SELECT SUM(a1), distinct(c1, c2)` is not a 
valid usage, even though this is not supported by the parser, because users 
might have been implied that `distinct(col list)` is a valid aggregate like 
usage. We at least need a better way to distinguish 1) select distinct col_list 
2) select distinct(col_list) 3) select agg1, agg2, distinct(col_list)`.  
   
   Given the reason above, I will close this PR and defer the handling for the 
distinct error described in this PR. 


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

Reply via email to