Re: Stored procedures returning rowsets - Mailing list pgsql-general

From Tom Lane
Subject Re: Stored procedures returning rowsets
Date
Msg-id 26239.1029252660@sss.pgh.pa.us
Whole thread Raw
In response to Re: Stored procedures returning rowsets  (Gregory Seidman <gss+pg@cs.brown.edu>)
List pgsql-general
Gregory Seidman <gss+pg@cs.brown.edu> writes:
> It is not, however, clear to me the difference between a stored procedure
> which can be CALL'd and a function which must be SELECT'd. Can anyone
> explain why the distinction is important?

As of 7.3 we should have reasonable support for functions returning
rowsets.  The main thing that a CALL-type interface could offer is the
ability for a single procedure call to return *multiple* rowsets.
You can sort of fake this now by returning multiple cursors, but it's
awkward.

The real problem with anything like this is figuring out how to
declare/bind/access output parameters from a CALL.  That doesn't
fit into SQL very well, since SQL has no such thing as a global
variable ...

            regards, tom lane

pgsql-general by date:

Previous
From: Mario Weilguni
Date:
Subject: Re: oid2name reports much fewer files...
Next
From: Andrew Sullivan
Date:
Subject: Re: [HACKERS] Linux Largefile Support In Postgresql RPMS