]> granicus.if.org Git - postgresql/commit
Fix "cannot handle unplanned sub-select" error that can occur when a
authorTom Lane <tgl@sss.pgh.pa.us>
Thu, 8 Jul 2010 00:14:04 +0000 (00:14 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Thu, 8 Jul 2010 00:14:04 +0000 (00:14 +0000)
commitd4d32eefdf3df4eb9aadea08e3d07af753457fbb
treefb6752d683f2d24c5956d8feebbb33e0ff6dd76e
parent5b1b3ef742723009e5f9b7a009aa8eda3578305a
Fix "cannot handle unplanned sub-select" error that can occur when a
sub-select contains a join alias reference that expands into an expression
containing another sub-select.  Per yesterday's report from Merlin Moncure
and subsequent off-list investigation.

Back-patch to 7.4.  Older versions didn't attempt to flatten sub-selects in
ways that would trigger this problem.
src/backend/optimizer/util/var.c
src/test/regress/expected/subselect.out
src/test/regress/sql/subselect.sql