summaryrefslogtreecommitdiff
path: root/mysql-test/t/func_math.test
diff options
context:
space:
mode:
authorAlexey Kopytov <Alexey.Kopytov@sun.com>2009-02-23 14:42:31 +0200
committerAlexey Kopytov <Alexey.Kopytov@sun.com>2009-02-23 14:42:31 +0200
commit8ae816240359d89554ffb2f5197666c71e45f1ba (patch)
tree8cbab18ef11dd6a2d9145bac3d88c64f57c3e062 /mysql-test/t/func_math.test
parent9fc083bd9ade238ed53f82978b5588f687b033c6 (diff)
parent0e62c9aa6301de71164496ec7c81c871d78ce8cd (diff)
downloadmariadb-git-8ae816240359d89554ffb2f5197666c71e45f1ba.tar.gz
Manual merge to 5.1.
Diffstat (limited to 'mysql-test/t/func_math.test')
-rw-r--r--mysql-test/t/func_math.test21
1 files changed, 21 insertions, 0 deletions
diff --git a/mysql-test/t/func_math.test b/mysql-test/t/func_math.test
index 87b172a6436..e67f5f29e3a 100644
--- a/mysql-test/t/func_math.test
+++ b/mysql-test/t/func_math.test
@@ -248,6 +248,27 @@ INSERT INTO t1 VALUES ('a');
SELECT a DIV 2 FROM t1 UNION SELECT a DIV 2 FROM t1;
DROP TABLE t1;
+#
+# Bug #15936: "round" differs on Windows to Unix
+#
+
+CREATE TABLE t1 (a DOUBLE);
+
+INSERT INTO t1 VALUES (-1.1), (1.1),
+ (-1.5), (1.5),
+ (-1.9), (1.9),
+ (-2.1), (2.1),
+ (-2.5), (2.5),
+ (-2.9), (2.9),
+# Check numbers with absolute values > 2^53 - 1
+# (see comments for MAX_EXACT_INTEGER)
+ (-1e16 - 0.5), (1e16 + 0.5),
+ (-1e16 - 1.5), (1e16 + 1.5);
+
+SELECT a, ROUND(a) FROM t1;
+
+DROP TABLE t1;
+
--echo End of 5.0 tests
#