Re: Limits of SQL

Поиск
Список
Период
Сортировка
От Bruno Wolff III
Тема Re: Limits of SQL
Дата
Msg-id 20050604202213.GA20567@wolff.to
обсуждение исходный текст
Ответ на Re: Limits of SQL  (Joachim Zobel <jzobel@heute-morgen.de>)
Ответы Re: Limits of SQL
Список pgsql-general
On Sat, Jun 04, 2005 at 21:53:24 +0200,
  Joachim Zobel <jzobel@heute-morgen.de> wrote:
> Am Samstag, den 04.06.2005, 07:38 -0500 schrieb Bruno Wolff III:
> > On Sat, Jun 04, 2005 at 11:31:02 +0200,
> >   Joachim Zobel <jzobel@heute-morgen.de> wrote:
> > >
> > > ... And it seems that
> > > a plain SELECT that tells me if a path exists is not possible...
> >
> > When 'WITH' gets implemented then you should be able to do this. I think
> > there was some recent talk about that, but I don't know if it is going to
> > make it in to 8.1. We'll know in about a month though.
>
> So WITH will allow recursion so I can walk the graph, right? Does this
> mean I can recursively join until a terminating condition is reached?

It can be used to compute transitive closures, which I think is what
you are really looking for.
If you look at the TODO page (http://www.postgresql.org/docs/faqs.TODO.html)
you will see two entries for WITH under Exotic Features:
Add SQL99 WITH clause to SELECT
Add SQL99 WITH RECURSIVE to SELECT

There is a short example of this on pages 439-440 of "SQL for Smarties"
second edition.

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

Предыдущее
От: Joachim Zobel
Дата:
Сообщение: Re: Limits of SQL
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: Rollback on Error