Equivalent to Oracle's inline CURSOR in a SELECT clause?

Поиск
Список
Период
Сортировка
От Doug Bloebaum
Тема Equivalent to Oracle's inline CURSOR in a SELECT clause?
Дата
Msg-id s12f170c.021@smtp.luxotticaretail.com
обсуждение исходный текст
Список pgsql-general
In Oracle I can do this:

SELECT h.transaction_number
       CURSOR(SELECT d.detail_number
                FROM detail d
               WHERE d.transaction_number=h.transaction_number)
  FROM header h
 WHERE h.transaction_date='25-aug-2004'

which comes in handy once in a while for nested parent/child
relationships, especially when using Oracle's XSQL servlet to produce
XML from queries.

Is there an equivalent syntax in PostgreSQL?

P.S. Half surprisingly, the Oracle XSQL servlet works just fine with
PostgreSQL as a backend!





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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Migrating between versions. Problem with regexp
Следующее
От: "Yateen Joshi"
Дата:
Сообщение: Single Row Table?