Barry Lind <barry@xythos.com> writes:
> It seems to me that the server has all the functionality to do this,
> because plpgsql supports it in 7.2. It just isn't can't be done from
> the client.
True. Basically it's a shortcoming in the FE/BE protocol. There's
some other work that'd have to be done, but extending the protocol
would be the main bit.
> I have been contemplating creating some SPI functions that could be
> called from the client that would implement this type of functionality
> and then enhancing the JDBC driver to use them instead of the regular
> query execution of the FE/BE protocol.
Interesting as a proof-of-concept hack, but I'd sure not want to see
it shipped as a production solution. For one thing, the existing
fastpath protocol is itself too broken to encourage more widespread
use of. (See the various comments in fastpath.c.)
regards, tom lane