AngersZhuuuu opened a new pull request #30805:
URL: https://github.com/apache/spark/pull/30805


   ### What changes were proposed in this pull request?
   We are easy to drop some column when use DF/DS api `drop` but difficult when 
use SQL when there are so many columns.
   Add a function to support this:
   
   
   ```
    usage = """
       _FUNC_(expr*) - Returns the columns except columns given in function 
parameters.
     """,
     examples = """
       Examples:
         > select * FROM TBL;
          A B C
          1 2 3
         > SELECT _FUNC_(a, b) FROM TBL;
          C
          3
   ```
   
   ### Why are the changes needed?
   Provide a way to handle  drop column in SQL
   
   
   ### Does this PR introduce _any_ user-facing change?
   Yes, user can use `all_columns_except` func in projection list to handle 
complex drop column  scenario
   
   
   ### How was this patch tested?
   Added UT
   


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

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