summaryrefslogtreecommitdiff
path: root/mysql-test/t
diff options
context:
space:
mode:
authorTimothy Smith <timothy.smith@sun.com>2008-12-15 13:09:23 -0700
committerTimothy Smith <timothy.smith@sun.com>2008-12-15 13:09:23 -0700
commit45c97126aff027e6179f850cd5d9793af3d9ccc8 (patch)
treeb25c410b383f903a1fa134fd697c0141f6c3cea9 /mysql-test/t
parent001aaedcb662adb2955fa9cd705ba0906ddea2a5 (diff)
parentaf5cf536bc5246e49a4874a225931a838659cae0 (diff)
downloadmariadb-git-45c97126aff027e6179f850cd5d9793af3d9ccc8.tar.gz
Merge from upstream 5.0-bugteam.
Diffstat (limited to 'mysql-test/t')
-rw-r--r--mysql-test/t/func_if.test14
-rw-r--r--mysql-test/t/mysql.test19
2 files changed, 33 insertions, 0 deletions
diff --git a/mysql-test/t/func_if.test b/mysql-test/t/func_if.test
index 8da10f36cbe..4efea8e195e 100644
--- a/mysql-test/t/func_if.test
+++ b/mysql-test/t/func_if.test
@@ -150,4 +150,18 @@ FROM t1;
DROP TABLE t1;
+#
+# Bug #40761: Assert on sum func on IF(..., CAST(longtext AS UNSIGNED), signed)
+# (was: LEFT JOIN on inline view crashes server)
+#
+
+CREATE TABLE t1 (c LONGTEXT);
+INSERT INTO t1 VALUES(1), (2), (3), (4), ('12345678901234567890');
+
+SELECT * FROM (SELECT MAX(IF(1, CAST(c AS UNSIGNED), 0)) FROM t1) AS te;
+SELECT * FROM (SELECT MAX(IFNULL(CAST(c AS UNSIGNED), 0)) FROM t1) AS te;
+
+DROP TABLE t1;
+
+
--echo End of 5.0 tests
diff --git a/mysql-test/t/mysql.test b/mysql-test/t/mysql.test
index 182b292c817..76941af893a 100644
--- a/mysql-test/t/mysql.test
+++ b/mysql-test/t/mysql.test
@@ -290,4 +290,23 @@ EOF
--exec $MYSQL < $MYSQLTEST_VARDIR/tmp/bug29323.sql 2>&1
remove_file $MYSQLTEST_VARDIR/tmp/bug29323.sql;
+#
+# Bug #33812: mysql client incorrectly parsing DELIMITER
+#
+# The space and ; after delimiter are important
+--exec $MYSQL -e "select 1 delimiter ;"
+
+#
+# Bug #38158: mysql client regression, can't read dump files
+#
+--write_file $MYSQLTEST_VARDIR/tmp/bug38158.sql
+-- Testing
+--
+delimiter ||
+select 2 ||
+EOF
+--exec $MYSQL < $MYSQLTEST_VARDIR/tmp/bug38158.sql 2>&1
+--exec $MYSQL -c < $MYSQLTEST_VARDIR/tmp/bug38158.sql 2>&1
+remove_file $MYSQLTEST_VARDIR/tmp/bug38158.sql;
+
--echo End of 5.0 tests