Joe Conway wrote:
> Joe Conway wrote:
> >Kevin Brown wrote:
> >
> >>Won't dblink's attempt to initiate a transaction simply return with a
> >>warning if a transaction is already in progress? This is what psql
> >>does, and it's also what happens with Perl DBI, so it's only if dblink
> >>freaks out that there will be a problem.
> >>
> >>I wouldn't expect it to abort the entire (already running)
> >>transaction upon receipt of a warning...
> >
>
> [...snip...]
>
> >
> >regression=# SELECT dblink_close('rmt_foo_cursor');
>
> But then again, dblink_close issues a COMMIT, so beware...
Ooops. Forgot about that.
The code change I'd make is to not issue the COMMIT if the previous
BEGIN generated a warning. Is there any way for dblink to detect
that?
--
Kevin Brown kevin@sysexperts.com