Skip site navigation (1) Skip section navigation (2)

Re: Common Table Expressions (WITH RECURSIVE) patch

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Greg Stark <greg(dot)stark(at)enterprisedb(dot)com>
Cc: Jeff Davis <pgsql(at)j-davis(dot)com>, Tatsuo Ishii <ishii(at)postgresql(dot)org>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Common Table Expressions (WITH RECURSIVE) patch
Date: 2008-10-01 03:10:51
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
Here are the results of a couple more days' hacking on the CTE patch.

* I cleaned up the processing in the second part of parse_cte.c, where
we are trying to check for validity of a recursive query.  The
conditions that it's checking for are not exactly the same as what was
being looked for previously, so this could do with a bit of review.

* I got rid of the kluges in the executor in favor of treating the
working table as a PARAM_EXEC Param.  Also renamed the plan node
types to RecursiveUnion and WorkTableScan --- I'm not wedded to these
choices, but they seemed more transparent than the former names.

* I have not yet tackled the problem of ensuring single evaluation of
CTEs, but there's a few bits of infrastructure for it.

There are various small loose ends denoted by XXX in the patch, but
the main remaining issue is definitely the single-evaluation business.

			regards, tom lane

Attachment: cte-0930.patch.gz
Description: application/octet-stream (43.2 KB)

In response to

pgsql-hackers by date

Next:From: Tom LaneDate: 2008-10-01 04:09:28
Subject: Re: Bad error message
Previous:From: Gurjeet SinghDate: 2008-10-01 02:36:53
Subject: Re: Bad error message

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group