Re: [HACKERS] SQL procedures - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: [HACKERS] SQL procedures
Date
Msg-id 795c6fe1-6236-ae5c-f7b2-8f6d0a7df535@2ndquadrant.com
Whole thread Raw
In response to Re: [HACKERS] SQL procedures  (Craig Ringer <craig@2ndquadrant.com>)
List pgsql-hackers
On 11/23/17 00:59, Craig Ringer wrote:
>     Exactly. If we want to handle OUT params this way they really need to be
>     the first resultset for just this reason. That could possibly be done by
>     the glue code reserving a spot in the resultset list and filling it in
>     at the end of the procedure.
> 
> I fail to understand how that can work though. Wouldn't we have to
> buffer all the resultset contents on the server in tuplestores or
> similar, so we can send the parameters and then the result sets?

The current PoC in the other thread puts the extra result sets in
cursors.  That's essentially the buffer you are referring to.  So it
seems possible, but there are some details to be worked out.

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


pgsql-hackers by date:

Previous
From: Peter Eisentraut
Date:
Subject: documentation is now XML
Next
From: Peter Eisentraut
Date:
Subject: Re: has_sequence_privilege() never got the memo