Robert Haas wrote:
Thanks. I read through this patch some more tonight and I guess I am a bit confused about what it accomplishes. AIUI, the point here is to lay the groundwork for a future patch to allow writeable CTEs, and I guess I'm not understanding how it's going to do that.
The purpose of this patch is only to move INSERT, UPDATE and DELETE into plan nodes because for writeable CTEs, we can't use the currently existing way of handling those operations. My previous approach was to only add a special-case node for RETURNING and use the top-level INSERT/UPDATE/DELETE handling like now, but that would've lead to copying a lot of code, as Tom pointed out in http://archives.postgresql.org/pgsql-hackers/2009-07/msg01217.php . In that same message, Tom suggested the current approach which to me seems like the best way to tackle this. This patch alone doesn't accomplish anything, but supporting writeable CTEs will be a lot easier as seen in the git repo David pointed you to. Regards, Marko Tiikkaja -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers