stefanbuk-db commented on code in PR #45407:
URL: https://github.com/apache/spark/pull/45407#discussion_r1519220632


##########
sql/api/src/main/scala/org/apache/spark/sql/catalyst/util/SparkIntervalUtils.scala:
##########
@@ -229,13 +237,21 @@ trait SparkIntervalUtils {
               try {
                 currentValue = Math.addExact(Math.multiplyExact(10, 
currentValue), (b - '0'))
               } catch {
-                case e: ArithmeticException => throwIAE(e.getMessage, e)
+                case e: ArithmeticException => throw new 
SparkIllegalArgumentException(
+                  errorClass = "INVALID_INTERVAL_FORMAT.ARITHMETIC_EXCEPTION",

Review Comment:
   It is related to illegal parsed value in interval format argument, thats why 
we throw this error.



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

Reply via email to