Re: Common Table Expressions applied; some issues remain

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Hitoshi Harada <umi(dot)tanuki(at)gmail(dot)com>
Cc: Greg Stark <stark(at)enterprisedb(dot)com>, Yoshiyuki Asaba <y-asaba(at)sraoss(dot)co(dot)jp>, Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Common Table Expressions applied; some issues remain
Date: 2009-05-27 03:36:34
Message-ID: 26465.1243395394@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hitoshi Harada <umi(dot)tanuki(at)gmail(dot)com> writes:
> 2009/5/27 Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>:
>> I could still see doing what I mentioned in the prior message, which is
>> to flatten CTEs as if they are plain sub-selects when
>>
>> 1. they are non-recursive,
>> 2. they are referenced only once, and
>> 3. they contain no volatile functions.

> And 4. only if the sub-selects use index scan? Or in other cases would
> it be effective?

Uh ... you've got the causality backwards, and I don't see the point of
such a restriction anyway.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2009-05-27 03:44:30 Re: [HACKERS] commitfest management webapp
Previous Message Hitoshi Harada 2009-05-27 03:29:58 Re: Common Table Expressions applied; some issues remain