Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Not a Bug
-
5.5.67, 10.4.12, 5.5(EOL), 10.0(EOL), 10.1(EOL), 10.2(EOL), 10.3(EOL), 10.4(EOL)
-
None
Description
If you use the round function within an if or case construct, the number of digits may not be correct.
Statement: select if(true, round(1.190000, 2), round(1.00000, 6));
Expected result: 1.19
Actual result: 1.190000
Workaround: Move the round outside.
Statement: select round(if(true, 1.190000, 1.000000), if(true, 2, 6));
Expected result: 1.19
Actual result: 1.19
The bug came from version 5.5.32 to version 5.5.33 and from version 10.0.4 to version 10.0.5.
The 10.1, 10.2, 10.3 and 10.4 branches are affected in all versions.
Attachments
Issue Links
- duplicates
-
MDEV-7297 IF() function consults 3rd argument to determine result display
- Closed