diff options
author | unknown <hf@deer.(none)> | 2005-06-15 19:53:40 +0500 |
---|---|---|
committer | unknown <hf@deer.(none)> | 2005-06-15 19:53:40 +0500 |
commit | df60c7ef2dfffc0cc4b86da8b57449c11f7bbcbe (patch) | |
tree | 3585affbc0a60dc069a04503309966ca2239f010 /mysql-test | |
parent | b0502fc200e0dc6664d5e168750e6081f79f279a (diff) | |
download | mariadb-git-df60c7ef2dfffc0cc4b86da8b57449c11f7bbcbe.tar.gz |
Fix for bug #10632 (CEILING returns wrong result)
mysql-test/r/func_math.result:
test result fixed
mysql-test/t/func_math.test:
test case added
strings/decimal.c:
handling of round_digit changed - we have to check all the digits after
the point if round_digit is 0
Diffstat (limited to 'mysql-test')
-rw-r--r-- | mysql-test/r/func_math.result | 6 | ||||
-rw-r--r-- | mysql-test/t/func_math.test | 7 |
2 files changed, 13 insertions, 0 deletions
diff --git a/mysql-test/r/func_math.result b/mysql-test/r/func_math.result index c7674c57c8d..b7188092b41 100644 --- a/mysql-test/r/func_math.result +++ b/mysql-test/r/func_math.result @@ -146,3 +146,9 @@ drop table t1; select round(150, 2); round(150, 2) 150.00 +select ceil(0.09); +ceil(0.09) +1 +select ceil(0.000000000000000009); +ceil(0.000000000000000009) +1 diff --git a/mysql-test/t/func_math.test b/mysql-test/t/func_math.test index 03057af6911..da4b8335e07 100644 --- a/mysql-test/t/func_math.test +++ b/mysql-test/t/func_math.test @@ -84,3 +84,10 @@ drop table t1; # Bug #10083 (round doesn't increase decimals) # select round(150, 2); + +# +# Bug @10632 (Ceiling function returns wrong answer) +# +select ceil(0.09); +select ceil(0.000000000000000009); + |