From: | Zoltan Boszormenyi <zb(at)cybertec(dot)at> |
---|---|
To: | Martijn van Oosterhout <kleptog(at)svana(dot)org> |
Cc: | Gregory Stark <stark(at)enterprisedb(dot)com>, Tatsuo Ishii <ishii(at)postgresql(dot)org>, David Fetter <david(at)fetter(dot)org>, PG Hackers <pgsql-hackers(at)postgresql(dot)org>, pgsql-patches(at)postgresql(dot)org |
Subject: | Re: [HACKERS] WITH RECURSIVE patch V0.1 |
Date: | 2008-05-19 09:56:17 |
Message-ID: | 48314EC1.5070504@cybertec.at |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-patches |
Martijn van Oosterhout írta:
> On Mon, May 19, 2008 at 08:19:17AM +0200, Zoltan Boszormenyi wrote:
>
>>> The standard has a clause to specify depth-first order. However doing a
>>> depth-first traversal would necessitate quite a different looking plan and
>>> it's far less obvious (to me anyways) how to do it.
>>>
>> That would be even cooler to have it implemented as well.
>>
>
> From an implementation point of view, the only difference between
> breadth-first and depth-first is that your tuplestore needs to be LIFO
> instead of FIFO.
Are you sure? I think a LIFO tuplestore would simply return reversed
breadth-first order. Depth-first means for every new record descend into
another recursion first then continue with the next record on the right.
> However, just looking at the plan I don't know whether
> it could support that kind of usage. At the very least I don't think
> the standard tuplestore code can handle it.
>
--
----------------------------------
Zoltán Böszörményi
Cybertec Schönig & Schönig GmbH
http://www.postgresql.at/
From | Date | Subject | |
---|---|---|---|
Next Message | Martijn van Oosterhout | 2008-05-19 10:06:30 | Re: [HACKERS] WITH RECURSIVE patch V0.1 |
Previous Message | Fabien COELHO | 2008-05-19 09:42:24 | triggers on prepare, commit, rollback... ? |
From | Date | Subject | |
---|---|---|---|
Next Message | Martijn van Oosterhout | 2008-05-19 10:06:30 | Re: [HACKERS] WITH RECURSIVE patch V0.1 |
Previous Message | Zoltan Boszormenyi | 2008-05-19 09:15:02 | Re: [HACKERS] WITH RECURSIVE patch V0.1 |