Fix some issues with LATERAL(SELECT UNION ALL SELECT).
authorTom Lane <tgl@sss.pgh.pa.us>
Sat, 11 Aug 2012 22:42:20 +0000 (18:42 -0400)
committerTom Lane <tgl@sss.pgh.pa.us>
Sat, 11 Aug 2012 22:42:56 +0000 (18:42 -0400)
commite76af54137c051cafcb1e39f68383a31d1d55ff6
tree3aebae04ee3afdbccc059ea941ba8921b5620776
parent83af58f6b5657840f5924332fccecca1e3556abe
Fix some issues with LATERAL(SELECT UNION ALL SELECT).

The LATERAL marking has to be propagated down to the UNION leaf queries
when we pull them up.  Also, fix the formerly stubbed-off
set_append_rel_pathlist().  It does already have enough smarts to cope with
making a parameterized Append path at need; it just has to not assume that
there *must* be an unparameterized path.
src/backend/optimizer/path/allpaths.c
src/backend/optimizer/prep/prepjointree.c
src/test/regress/expected/join.out
src/test/regress/sql/join.sql