summaryrefslogtreecommitdiff
path: root/mysql-test/t/func_gconcat.test
diff options
context:
space:
mode:
Diffstat (limited to 'mysql-test/t/func_gconcat.test')
-rw-r--r--mysql-test/t/func_gconcat.test10
1 files changed, 9 insertions, 1 deletions
diff --git a/mysql-test/t/func_gconcat.test b/mysql-test/t/func_gconcat.test
index e4a1206fa9c..936b93b49c9 100644
--- a/mysql-test/t/func_gconcat.test
+++ b/mysql-test/t/func_gconcat.test
@@ -375,7 +375,7 @@ select group_concat('x') UNION ALL select 1;
drop table t1;
#
-# Bug #12863 : missing separators after first empty cancatanated elements
+# Bug #12863 : missing separators after first empty concatenated elements
#
CREATE TABLE t1 (id int, a varchar(9));
@@ -795,3 +795,11 @@ INSERT INTO t2 SELECT GROUP_CONCAT(a), b FROM t1 GROUP BY b;
SET group_concat_max_len = DEFAULT;
SET @@sql_mode = @old_sql_mode;
DROP TABLE t1, t2;
+
+#
+# MDEV-3987 uninitialized read in Item_cond::fix_fields leads to crash: select .. where .. in ( select ... )
+#
+create table t1 (a char(1) character set utf8);
+insert into t1 values ('a'),('b');
+select 1 from t1 where a in (select group_concat(a) from t1);
+drop table t1;