Description
As pointed out in https://github.com/apache/spark/pull/20350#issuecomment-505997469, in special cases of decimal aggregation we are using the `MakeDecimal` operator.
This operator has a not well defined behavior in case of overflow, namely what it does currently is:
- if codegen is enabled it returns null;
- in interpreted mode it throws an `IllegalArgumentException`.
So we should make his behavior uniform with other similar cases and in particular we should honor the value of the conf introduced in SPARK-23179 and behave accordingly, ie.:
- returning null if the flag is true;
- throw an `ArithmeticException` if the flag is false.
Attachments
Issue Links
- relates to
-
SPARK-23179 Support option to throw exception if overflow occurs during Decimal arithmetic
- Resolved
- links to