Re: returning multiple result sets from a stored procedure

From: Merlin Moncure <mmoncure(at)gmail(dot)com>
To: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Cc: John Adams <john_adams_mail(at)yahoo(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: returning multiple result sets from a stored procedure
Date: 2010-09-03 19:27:19
Message-ID: AANLkTin4hPHBp9rRV5JZmd_Wrb+T94NmaZ8S-OCVUqf5@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Sep 2, 2010 at 7:17 PM, Alvaro Herrera
<alvherre(at)commandprompt(dot)com> wrote:
> Excerpts from John Adams's message of jue sep 02 18:25:45 -0400 2010:
>> I noticed in postgres you cannot return multiple result sets from a stored
>> procedure (surprisingly as it looks like a very good dbms).
>
> If you're really intent about doing this, you can emulate it by
> returning a set of refcursors.

Also arrays can work pretty well, depending on how much data there is
and where it's going.

merlin

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Martijn van Oosterhout 2010-09-03 19:30:42 Re: Streaming a base backup from master
Previous Message Ron Mayer 2010-09-03 19:11:58 Re: Interruptible sleeps (was Re: CommitFest 2009-07: Yay, Kevin! Thanks, reviewers!)