summaryrefslogtreecommitdiff
path: root/mysql-test/r/join_outer.result
diff options
context:
space:
mode:
Diffstat (limited to 'mysql-test/r/join_outer.result')
-rw-r--r--mysql-test/r/join_outer.result14
1 files changed, 14 insertions, 0 deletions
diff --git a/mysql-test/r/join_outer.result b/mysql-test/r/join_outer.result
index 7bc95e78041..723b2a88382 100644
--- a/mysql-test/r/join_outer.result
+++ b/mysql-test/r/join_outer.result
@@ -1822,4 +1822,18 @@ b c d
5 8 88
5 8 81
DROP TABLE t1,t2;
+#
+# Bug mdev-4336: LEFT JOIN with disjunctive
+# <non-nullable datetime field> IS NULL in WHERE
+# causes a hang and eventual crash
+#
+CREATE TABLE t1 (
+id int(11) NOT NULL,
+modified datetime NOT NULL,
+PRIMARY KEY (id)
+);
+SELECT a.* FROM t1 a LEFT JOIN t1 b ON a.id = b.id
+WHERE a.modified > b.modified or b.modified IS NULL;
+id modified
+DROP TABLE t1;
SET optimizer_switch=@save_optimizer_switch;