srielau commented on code in PR #36857:
URL: https://github.com/apache/spark/pull/36857#discussion_r898099564
##########
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/CastSuiteBase.scala:
##########
@@ -1272,4 +1272,37 @@ abstract class CastSuiteBase extends SparkFunSuite with
ExpressionEvalHelper {
"to restore the behavior before Spark 3.0."))
}
}
+
+ test("cast ANSI intervals to decimals") {
+ Seq(
Review Comment:
We need examples with rounding:
INTERVAL '12.123' SECOND AS DECIMAL(3, 1) => 12.1
INTERVAL '12.005' SECOND AS DECIMAL(4, 2) => 12.01
--
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]