beliefer opened a new pull request, #50129: URL: https://github.com/apache/spark/pull/50129
### What changes were proposed in this pull request? This PR proposes to add a new `visitCaseWhen` method to `V2ExpressionSQLBuilder`. ### Why are the changes needed? The origin visitCaseWhen method is not good for users when the case when statments is related to the data type. Such as: MsSqlServer cannot handle boolean expressions inside a CASE WHEN, it is necessary to convert those to another CASE WHEN expression that will return 1 or 0 depending on the result. So the old visitCaseWhen method is not flexible and introduce some hacker code. ### Does this PR introduce _any_ user-facing change? 'No'. Just add a new API. ### How was this patch tested? GA. ### 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: [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]
