urosstan-db opened a new pull request, #46594:
URL: https://github.com/apache/spark/pull/46594

   ### What changes were proposed in this pull request?
   Pass correct parameter list to 
`org.apache.spark.sql.catalyst.util.ResolveDefaultColumns#analyze` when it is 
invoked from 
`org.apache.spark.sql.connector.catalog.CatalogV2Util#structFieldToV2Column`.
   
   `org.apache.spark.sql.catalyst.util.ResolveDefaultColumns#analyze` method 
accepts 3 parameter
   
   1) Field to analyze
   2) Statement type - String
   3) Metadata key - CURRENT_DEFAULT or EXISTS_DEFAULT
   
   Method 
`org.apache.spark.sql.connector.catalog.CatalogV2Util#structFieldToV2Column`
   pass `fieldToAnalyze` and `EXISTS_DEFAULT` as second parameter, so it is not 
metadata key, instead of that, it is statement type, so different expression is 
analyzed.
   
   ### Why are the changes needed?
   It is needed to pass correct value to `Column` object
   
   ### Does this PR introduce _any_ user-facing change?
   It should not make any user-facing change since code.
   
   
   ### How was this patch tested?
   No special test added, because change is simple.
   
   ### Was this patch authored or co-authored using generative AI tooling?
   No


-- 
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: reviews-unsubscr...@spark.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to