A bit more obvious example. The subquery in the WHERE clause produces a single NULL,
and is essential for the wrong result. Therefore this bug looks like an edge case.
SELECT MAX( t1.f3 ) AS field1
FROM t1 JOIN t2 ON t2.f1 != 0
WHERE ( SELECT f3 FROM t3 )
HAVING field1 is not null;
+--------+
| field1 |
+--------+
| NULL |
+--------+
A bit more obvious example. The subquery in the WHERE clause produces a single NULL,
and is essential for the wrong result. Therefore this bug looks like an edge case.
SELECT MAX( t1.f3 ) AS field1
FROM t1 JOIN t2 ON t2.f1 != 0
WHERE ( SELECT f3 FROM t3 )
HAVING field1 is not null;
+--------+
| field1 |
+--------+
| NULL |
+--------+