summaryrefslogtreecommitdiff
path: root/mysql-test/main/func_math.result
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2020-03-20 18:08:16 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2020-03-20 18:12:17 +0200
commit44298e4dea39280187c587c6e776ce8d04e350de (patch)
tree15f8bac3c985c4f07fd6af066439d046dbb13c35 /mysql-test/main/func_math.result
parentdd68db0c17d674f1b64e70ff7ea9e3f4abe4ee3e (diff)
parent9f7b8625e698da6b7eba7c26e765c66635571919 (diff)
downloadmariadb-git-44298e4dea39280187c587c6e776ce8d04e350de.tar.gz
Merge 10.2 into 10.3
Also, clean up the test innodb_gis.geometry a little further.
Diffstat (limited to 'mysql-test/main/func_math.result')
-rw-r--r--mysql-test/main/func_math.result48
1 files changed, 48 insertions, 0 deletions
diff --git a/mysql-test/main/func_math.result b/mysql-test/main/func_math.result
index 7176c38aa94..cd031c4b0e4 100644
--- a/mysql-test/main/func_math.result
+++ b/mysql-test/main/func_math.result
@@ -967,6 +967,54 @@ STDDEV_SAMP(a)
NULL
DROP TABLE t1;
#
+# MDEV-21977 main.func_math fails due to undefined behaviour
+#
+SELECT 9223372036854775808 DIV 1;
+9223372036854775808 DIV 1
+9223372036854775808
+SELECT 9223372036854775808 DIV -1;
+ERROR 22003: BIGINT UNSIGNED value is out of range in '9223372036854775808 DIV -1'
+SELECT -9223372036854775808 DIV 1;
+ERROR 22003: BIGINT value is out of range in '-9223372036854775808 DIV 1'
+SELECT -9223372036854775808 DIV -1;
+ERROR 22003: BIGINT value is out of range in '-9223372036854775808 DIV -1'
+SELECT 9223372036854775808 MOD 1;
+9223372036854775808 MOD 1
+0
+SELECT 9223372036854775808 MOD -1;
+9223372036854775808 MOD -1
+0
+SELECT -9223372036854775808 MOD 1;
+-9223372036854775808 MOD 1
+0
+SELECT -9223372036854775808 MOD -1;
+-9223372036854775808 MOD -1
+0
+SELECT 1 MOD 9223372036854775808;
+1 MOD 9223372036854775808
+1
+SELECT -1 MOD 9223372036854775808;
+-1 MOD 9223372036854775808
+-1
+SELECT 1 MOD -9223372036854775808;
+1 MOD -9223372036854775808
+1
+SELECT -1 MOD -9223372036854775808;
+-1 MOD -9223372036854775808
+-1
+SELECT 9223372036854775808 MOD 9223372036854775808;
+9223372036854775808 MOD 9223372036854775808
+0
+SELECT 9223372036854775808 MOD -9223372036854775808;
+9223372036854775808 MOD -9223372036854775808
+0
+SELECT -9223372036854775808 MOD 9223372036854775808;
+-9223372036854775808 MOD 9223372036854775808
+0
+SELECT -9223372036854775808 MOD -9223372036854775808;
+-9223372036854775808 MOD -9223372036854775808
+0
+#
# End of 10.1 tests
#
#