MaxGekk opened a new pull request, #37464: URL: https://github.com/apache/spark/pull/37464
### What changes were proposed in this pull request? This is a follow up of https://github.com/apache/spark/pull/37442 that fixes the codegen of casting integrals to ANSI intervals w/ multi units. The PR removes the assert: ```scala assert(it.startField == it.endField) ``` ### Why are the changes needed? To make codegen consistent to interpreted code, and fix the assert. ### Does this PR introduce _any_ user-facing change? Yes. Before: ```sql > select cast(dt as interval hour to second) from values(100Y) as t(dt); java.lang.AssertionError assertion failed ``` After: ```sql > select cast(dt as interval hour to second) from values(100Y) as t(dt); 0 00:01:40.000000000 ``` ### How was this patch tested? By running new tests: ``` $ build/sbt "sql/testOnly org.apache.spark.sql.SQLQueryTestSuite -- -z cast.sql" ``` -- 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]
