From: | David Fetter <david(at)fetter(dot)org> |
---|---|
To: | Abhijit Menon-Sen <ams(at)oryx(dot)com> |
Cc: | plperlng-devel(at)pgfoundry(dot)org, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: creating WITH HOLD cursors using SPI |
Date: | 2005-06-13 16:51:30 |
Message-ID: | 20050613165130.GC24030@fetter.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Mon, Jun 13, 2005 at 07:39:40PM +0530, Abhijit Menon-Sen wrote:
> At 2005-06-12 14:54:47 +0530, ams(at)oryx(dot)com wrote:
> >
> > The idea is to have spi_query call SPI_prepare/SPI_open_cursor,
> > and have an spi_fetchrow that calls SPI_cursor_fetch. It works
> > well enough, but I don't know how to reproduce spi_exec_query's
> > error handling (it runs the SPI_execute in a subtransaction).
>
> One possibility would be to make plperl_call_handler create the
> internal subtransaction, so that all of the perl code runs inside
> it. But I'm not sure if that would actually work, especially if one
> of the SPI functions failed. But I can't think of what else to do,
> either.
>
> Thoughts?
I have some :)
If we figure this out for PL/Perl, the general method will be
applicable to PL/YourFavoriteLanguage, so even if you're not a fan of
Perl, it's worth looking into.
Cheers,
D
--
David Fetter david(at)fetter(dot)org http://fetter.org/
phone: +1 510 893 6100 mobile: +1 415 235 3778
Remember to vote!
From | Date | Subject | |
---|---|---|---|
Next Message | Marc G. Fournier | 2005-06-13 17:08:44 | Re: The Contrib Roundup (long) |
Previous Message | Scott Marlowe | 2005-06-13 15:14:35 | Re: mirroring oracle database in pgsql |