Equivalent to Oracle's inline CURSOR in a SELECT clause? - Mailing list pgsql-general

From Doug Bloebaum
Subject Equivalent to Oracle's inline CURSOR in a SELECT clause?
Date
Msg-id s12f170c.021@smtp.luxotticaretail.com
Whole thread Raw
List 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 by date:

Previous
From: Tom Lane
Date:
Subject: Re: Migrating between versions. Problem with regexp
Next
From: "Yateen Joshi"
Date:
Subject: Single Row Table?