summaryrefslogtreecommitdiff
path: root/mysql-test/r/group_by.result
diff options
context:
space:
mode:
Diffstat (limited to 'mysql-test/r/group_by.result')
-rw-r--r--mysql-test/r/group_by.result14
1 files changed, 14 insertions, 0 deletions
diff --git a/mysql-test/r/group_by.result b/mysql-test/r/group_by.result
index 0858198694b..9a259b3c4c6 100644
--- a/mysql-test/r/group_by.result
+++ b/mysql-test/r/group_by.result
@@ -2494,6 +2494,20 @@ WHERE t1a.c1 = c2 GROUP BY i2;
i2
DROP TABLE t1,t2;
#
+# MDEV-6855
+# MIN(*) with subqueries with IS NOT NULL in WHERE clause crashed.
+#
+CREATE TABLE t1 (i INT, c VARCHAR(3), KEY(c,i)) ENGINE=MyISAM;
+INSERT INTO t1 VALUES (7,'foo'),(0,'bar');
+CREATE TABLE t2 (j INT) ENGINE=MyISAM;
+INSERT INTO t2 VALUES (0),(8),(1),(8),(9);
+SELECT MAX(i), c FROM t1
+WHERE c != 'qux' AND ( SELECT SUM(j) FROM t1, t2 ) IS NOT NULL GROUP BY c;
+MAX(i) c
+0 bar
+7 foo
+drop table t1,t2;
+#
# Bug #58782
# Missing rows with SELECT .. WHERE .. IN subquery
# with full GROUP BY and no aggr