|
I tried to test ROUND() with differnet situstions, but I did not find any issue.
==============================================================================
|
|
TEST RESULT TIME (ms) or COMMENT
|
--------------------------------------------------------------------------
|
|
worker[1] Using MTR_BUILD_THREAD 300, with reserved ports 16000..16019
|
#
|
# Test Round() for different decimal
|
#
|
# Deciamal is 0
|
Select ROUND(3.05);
|
ROUND(3.05)
|
3
|
Select ROUND(3.15);
|
ROUND(3.15)
|
3
|
Select ROUND(3.25);
|
ROUND(3.25)
|
3
|
Select ROUND(3.35);
|
ROUND(3.35)
|
3
|
Select ROUND(3.45);
|
ROUND(3.45)
|
3
|
Select ROUND(3.50);
|
ROUND(3.50)
|
4
|
Select ROUND(3.65);
|
ROUND(3.65)
|
4
|
Select ROUND(3.75);
|
ROUND(3.75)
|
4
|
Select ROUND(3.85);
|
ROUND(3.85)
|
4
|
Select ROUND(3.95);
|
ROUND(3.95)
|
4
|
|
# Deciamal is 1
|
|
Select ROUND(3.05,1);
|
ROUND(3.05,1)
|
3.1
|
Select ROUND(3.15,1);
|
ROUND(3.15,1)
|
3.2
|
Select ROUND(3.25,1);
|
ROUND(3.25,1)
|
3.3
|
Select ROUND(3.35,1);
|
ROUND(3.35,1)
|
3.4
|
Select ROUND(3.45,1);
|
ROUND(3.45,1)
|
3.5
|
Select ROUND(3.55,1);
|
ROUND(3.55,1)
|
3.6
|
Select ROUND(3.65,1);
|
ROUND(3.65,1)
|
3.7
|
Select ROUND(3.75, 1);
|
ROUND(3.75, 1)
|
3.8
|
Select ROUND(3.85, 1);
|
ROUND(3.85, 1)
|
3.9
|
Select ROUND(3.95, 1);
|
ROUND(3.95, 1)
|
4.0
|
|
# Deciamal is 2
|
|
Select ROUND(3.055,2);
|
ROUND(3.055,2)
|
3.06
|
Select ROUND(3.155,2);
|
ROUND(3.155,2)
|
3.16
|
Select ROUND(3.255,2);
|
ROUND(3.255,2)
|
3.26
|
Select ROUND(3.355,2);
|
ROUND(3.355,2)
|
3.36
|
Select ROUND(3.455,2);
|
ROUND(3.455,2)
|
3.46
|
Select ROUND(3.555,2);
|
ROUND(3.555,2)
|
3.56
|
Select ROUND(3.655,2);
|
ROUND(3.655,2)
|
3.66
|
Select ROUND(3.755, 2);
|
ROUND(3.755, 2)
|
3.76
|
Select ROUND(3.855, 2);
|
ROUND(3.855, 2)
|
3.86
|
Select ROUND(3.955, 2);
|
ROUND(3.955, 2)
|
3.96
|
main.func_round [ pass ] 7
|
--------------------------------------------------------------------------
|
The servers were restarted 0 times
|
Spent 0.007 of 2 seconds executing testcases
|
|
Completed: All 1 tests were successful.
|
|