yihua opened a new issue, #20839:
URL: https://github.com/apache/hudi/issues/20839

   A Spark SQL UPDATE that assigns a field of a struct column fails on a Hudi 
table:
   
   ```sql
   UPDATE t SET s.c1 = 1 WHERE id = 1
   ```
   
   fails with `scala.MatchError` in `UpdateHoodieTableCommand`, and the same 
assignment in a MERGE INTO action fails with "Only assignments of the form 
t.field = ... are supported" or an assertion on the number of update 
assignments. Spark supports these assignments on tables with row-level 
operations by rebuilding the top-level struct (`AssignmentUtils`).
   
   Proposal: align the assignments of UPDATE and MERGE INTO through 
`AssignmentUtils` (Spark 3.5 and later), so a nested assignment becomes an 
assignment of the rebuilt struct, and fail with a clear message on Spark 3.3 
and 3.4.
   


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