Re: Recursive Queries

Поиск
Список
Период
Сортировка
От Gregory Stark
Тема Re: Recursive Queries
Дата
Msg-id 87tzyfb5ps.fsf@stark.xeocode.com
обсуждение исходный текст
Ответ на Re: Recursive Queries  (Martijn van Oosterhout <kleptog@svana.org>)
Ответы Re: Recursive Queries  ("Joshua D. Drake" <jd@commandprompt.com>)
Список pgsql-hackers
"Martijn van Oosterhout" <kleptog@svana.org> writes:

> On Thu, Jan 25, 2007 at 11:08:14AM +0000, Gregory Stark wrote:
>> b) I do want to be able to support depth-first searching too. I'm not sure how
>> to reconcile that with the repeated-join conceptual model. We could always
>> resort the entire result set after generating it but that seems like an
>> unsatisfactory solution.
>
> If you have a tuplestore storing the intermediate tuples for looping,
> then surely the only difference between depth and breadth searching is
> that for the former new tuples goes to the front of the tuplestore, and
> the latter to the end.

That's basically how the existing patch approached the problem. It invents a
new type of join and a new type of tuplestore that behaves this way. This has
the advantage of working the way Oracle users expect and being relatively
simple conceptually. It has the disadvantage of locking us into what's
basically a nested loop join and not reusing existing join code so it's quite
a large patch.

--  Gregory Stark EnterpriseDB          http://www.enterprisedb.com


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Gregory Stark
Дата:
Сообщение: Re: Questions about warnings
Следующее
От: Gavin Sherry
Дата:
Сообщение: Re: Questions about warnings