Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
None
-
None
-
None
Description
CREATE TABLE test (a DECIMAL(38,18), b DECIMAL(38,18)); INSERT OVERWRITE TABLE test VALUES (20, 20); SELECT a*b from test
The returned result is NULL (instead of 400)
It is because Hive adds the scales from operands and the type for a*b is set to decimal (38, 36). Hive could not handle this case properly (e.g. by rounding)
Attachments
Issue Links
- relates to
-
HIVE-14347 Inconsistent hehavior in decimal multiplication
- Open