On 2010-11-07 6:23 PM +0200, Tom Lane wrote:
> Hitoshi Harada<umi.tanuki@gmail.com> writes:
>> Up to now, in a portal we only have multiple plans that share nothing
>> but relations, then executor starts, runs and ends separately.
>> Writeable CTEs need the result tuplestore of separated plans that were
>> executed before main query .
>
> Um ... why? I thought the whole point of breaking out ModifyTable
> as a separate node type was so that a query involving writeable CTEs
> would still be just one plan tree.
We tried that for 9.0 and it didn't work. Almost all work for 9.1 has
been spent on creating an infrastructure for running the executor
separately for every WITH list element when wCTEs are present.
Regards,
Marko Tiikkaja