Re: Utility of recursive queries?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Utility of recursive queries?
Дата
Msg-id 26575.1081528544@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Utility of recursive queries?  (James Robinson <jlrobins@socialserve.com>)
Список pgsql-sql
James Robinson <jlrobins@socialserve.com> writes:
> Given a reference to id=3, would a recursive query be the trick to 
> unrolling the list to discover id=1 as the head using a SQL one-liner? 

I think you could do it, but don't have the syntax in my head.

> would any potential recursive query implementation be 
> noticably more efficient that a straightforward implementation in 
> plpgsql

Most likely not ...
        regards, tom lane


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

Предыдущее
От: Josh Berkus
Дата:
Сообщение: Re: Utility of recursive queries?
Следующее
От: Greg Stark
Дата:
Сообщение: Re: SQL challenge--top 10 for each key value?