summaryrefslogtreecommitdiff
path: root/mysql-test/t/func_misc.test
diff options
context:
space:
mode:
authorgluh@eagle.(none) <>2007-12-13 16:10:57 +0400
committergluh@eagle.(none) <>2007-12-13 16:10:57 +0400
commitd504588e7948b1f8ed815a78aeb263471a1b6635 (patch)
tree2c8c40e7d9d218e840756bed5ba5cbd07e40d13b /mysql-test/t/func_misc.test
parent4f5868114a1fe46f139f80d894dd28f1f7c180c1 (diff)
parent9df070ed7c0f2877e71572e59aec871f4bc039fd (diff)
downloadmariadb-git-d504588e7948b1f8ed815a78aeb263471a1b6635.tar.gz
Merge mysql.com:/home/gluh/MySQL/Merge/5.0-opt
into mysql.com:/home/gluh/MySQL/Merge/5.1-opt
Diffstat (limited to 'mysql-test/t/func_misc.test')
-rw-r--r--mysql-test/t/func_misc.test14
1 files changed, 14 insertions, 0 deletions
diff --git a/mysql-test/t/func_misc.test b/mysql-test/t/func_misc.test
index 5a934ce712e..7a579088d23 100644
--- a/mysql-test/t/func_misc.test
+++ b/mysql-test/t/func_misc.test
@@ -214,6 +214,20 @@ SELECT NAME_CONST('test', -1.0);
SELECT NAME_CONST('test', 'test');
#
+# Bug #27545: erroneous usage of NAME_CONST with a name as the first parameter
+# resolved against a column name of a derived table hangs the client
+#
+
+CREATE TABLE t1 (a int);
+INSERT INTO t1 VALUES (5), (2);
+
+--error ER_WRONG_ARGUMENTS
+SELECT NAME_CONST(x,2) FROM (SELECT a x FROM t1) t;
+
+DROP TABLE t1;
+
+
+#
# Bug #32559: connection hangs on query with name_const
#
CREATE TABLE t1(a INT);