Details
-
Type:
Bug
-
Status: Open
-
Priority:
Minor
-
Resolution: Unresolved
-
Affects Version/s: 5.5.36, 10.0.9
-
Fix Version/s: 10.0
-
Component/s: None
-
Labels:None
Description
This SQL script:
DROP TABLE IF EXISTS t1; CREATE TABLE t1 (a DOUBLE); INSERT INTO t1 VALUES (1e30); SELECT SUM(a), CAST(SUM(a) AS SIGNED) FROM t1;
returns a wrong result for CAST(SUM(a) AS SIGNED):
+--------+------------------------+ | SUM(a) | CAST(SUM(a) AS SIGNED) | +--------+------------------------+ | 1e30 | -9223372036854775808 | +--------+------------------------+
The expected result is +9223372036854775807,
which is the maximum possible positive signed integer value.
Gliffy Diagrams
Attachments
Activity
- All
- Comments
- Work Log
- History
- Activity
- Transitions