Re: EXPLAIN WITH

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Stephen Frost <sfrost(at)snowman(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org, Robert Haas <robertmhaas(at)gmail(dot)com>
Subject: Re: EXPLAIN WITH
Date: 2009-04-05 16:05:28
Message-ID: 4984.1238947528@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Stephen Frost <sfrost(at)snowman(dot)net> writes:
> * Stephen Frost (sfrost(at)snowman(dot)net) wrote:
>> Would be nice if there was a CTE ID or similar to link between
>> the pieces of the InitPlan and the CTE nodes.

> Erm, of course, the CTE *has* an ID already, since you name them. Could
> we get that ID/name up into the piece of the InitPlan that is handling
> that CTE?

I'm not sure but will be glad to take a look. Assuming it's not
unreasonably difficult, does anyone object to a format like this:

Nested Loop (cost=1266.59..1001458.19 rows=35936310 width=52)
InitPlan
CTE abc
-> Seq Scan on foo (cost=0.00..34.25 rows=647 width=12)
Filter: (id < 200)
CTE wumpus
-> Seq Scan on tab1 (cost=0.00..27.70 rows=1770 width=16)
-> CTE Scan on abc x (cost=0.00..35.40 rows=1770 width=16)
-> Materialize (cost=1204.64..1566.67 rows=20303 width=36)
-> Hash Join (cost=42.05..1025.34 rows=20303 width=36)
...

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2009-04-05 16:21:41 Re: Closing some 8.4 open items
Previous Message Tom Lane 2009-04-05 15:54:03 Re: Python 3.0 does not work with PL/Python