Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> Got it. How does an IN subquery returning NULL behave differently from
> one returning FALSE? I can't think of a test that would be affected.
After we fix IS TRUE and friends to respond to nulls correctly (Conway's
promised to do that, IIRC) it'll be possible to write
(foo IN (SELECT ...)) IS NOT FALSE
and get the "intuitive" behavior. But right now that doesn't work.
Hm. Maybe we could recognize that construct as a whole, and translate
it to an optimizable join? It'd become the usual locution, I imagine.
regards, tom lane