Fix corner case wherein a WorkTableScan node could get initialized before the
authorTom Lane <tgl@sss.pgh.pa.us>
Mon, 13 Oct 2008 00:41:41 +0000 (00:41 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Mon, 13 Oct 2008 00:41:41 +0000 (00:41 +0000)
commit018f8b4a559d41708a9655c827b52f4f90a44a7c
tree2c9a6695411eeaa6129ef90704b4a99186b07137
parentbb203fcd5156af887c0c04ed07b1844e934d2242
Fix corner case wherein a WorkTableScan node could get initialized before the
RecursiveUnion to which it refers.  It turns out that we can just postpone the
relevant initialization steps until the first exec call for the node, by which
time the ancestor node must surely be initialized.  Per report from Greg Stark.
src/backend/executor/nodeWorktablescan.c
src/test/regress/expected/with.out
src/test/regress/sql/with.sql