Re: Implementing 2 different transactions in a PL/Perl function - Mailing list pgsql-general

From Richard Huxton
Subject Re: Implementing 2 different transactions in a PL/Perl function
Date
Msg-id 4693E702.1020607@archonet.com
Whole thread Raw
In response to Re: Implementing 2 different transactions in a PL/Perl function  ("Jasbinder Singh Bali" <jsbali@gmail.com>)
List pgsql-general
Jasbinder Singh Bali wrote:
> You mean to say keep using spi_exec till I want everything in the same
> transaction and the point where I want a separate transaction, use DBI ?

Yes - if you have two functions A,B then do everything as normal in
each, except you call function B using dblink() from function A. That
will give you a separate session which can commit/rollback separately
from the original.

--
   Richard Huxton
   Archonet Ltd

pgsql-general by date:

Previous
From: "Jasbinder Singh Bali"
Date:
Subject: Re: Implementing 2 different transactions in a PL/Perl function
Next
From: "Shuo Liu"
Date:
Subject: exit code -1073741819