Comment 1 for bug 714999

Revision history for this message
Timour Katchaounov (timour) wrote :

Slightly simpler query:

EXPLAIN
SELECT f2 FROM t3
WHERE (SELECT pk FROM t1
       WHERE EXISTS (SELECT DISTINCT f1 FROM t2)
) IS NULL ;

- distinct in the inner-most query is needed to force a temp table
- 'IS NULL' is needed too, not yet clear why