diff options
author | Alfranio Correia <alfranio.correia@sun.com> | 2008-12-13 19:42:12 +0000 |
---|---|---|
committer | Alfranio Correia <alfranio.correia@sun.com> | 2008-12-13 19:42:12 +0000 |
commit | 3175a06a13e10e3e321ca52d44619b8185cacc77 (patch) | |
tree | 3ca8c469534126c025304d8d96dbeb2b359a6c00 /mysql-test/t/func_sapdb.test | |
parent | 7434596b84e8f0ae09e9ec511e6720c84fdc4d26 (diff) | |
parent | 30d8a8f9503faab7df7cd2a742f8f87e9df43b40 (diff) | |
download | mariadb-git-3175a06a13e10e3e321ca52d44619b8185cacc77.tar.gz |
merge 5.1 --> 5.1-rpl
Diffstat (limited to 'mysql-test/t/func_sapdb.test')
-rw-r--r-- | mysql-test/t/func_sapdb.test | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/mysql-test/t/func_sapdb.test b/mysql-test/t/func_sapdb.test index 5db6db70e8f..f37ee0c39f0 100644 --- a/mysql-test/t/func_sapdb.test +++ b/mysql-test/t/func_sapdb.test @@ -135,3 +135,20 @@ select str_to_date("2003-01-02 10:11:12.0012", "%Y-%m-%d %H:%i:%S.%f"); --enable_ps_protocol # End of 4.1 tests + + + +# +# Bug#37553: MySql Error Compare TimeDiff & Time +# + +# calculations involving negative time values ignored sign +select timediff('2008-09-29 20:10:10','2008-09-30 20:10:10'),time('00:00:00'); +select timediff('2008-09-29 20:10:10','2008-09-30 20:10:10')>time('00:00:00'); +select timediff('2008-09-29 20:10:10','2008-09-30 20:10:10')<time('00:00:00'); + +# show that conversion to DECIMAL no longer drops sign +SELECT CAST(time('-73:42:12') AS DECIMAL); + + +# End of 5.0 tests |