Description
SQL ANSI 2011 states that in case of overflow during arithmetic operations, an exception should be thrown. This is what most of the SQL DBs do (eg. SQLServer, DB2). Hive currently returns NULL (as Spark does) but HIVE-18291 is open to be SQL compliant.
I propose to have a config option which allows to decide whether Spark should behave according to SQL standards or in the current way (ie. returning NULL).
Attachments
Issue Links
- is related to
-
SPARK-28024 Incorrect numeric values when out of range
- Open
-
SPARK-28200 Decimal overflow handling in ExpressionEncoder
- Resolved
-
SPARK-28201 Revisit MakeDecimal behavior on overflow
- Resolved
- relates to
-
HIVE-18291 An exception should be raised if the result is outside the range of decimal
- Open
-
SPARK-22036 BigDecimal multiplication sometimes returns null
- Resolved
- links to