On Thu, Jun 18, 2009 at 09:17:21PM +0100, Tim Bunce wrote:
> On Thu, Jun 18, 2009 at 11:50:04AM -0700, Darren Duncan wrote:
> > Tim Bunce wrote:
> >> On Wed, Jun 17, 2009 at 01:53:36PM -0500, David Dooling wrote:
> >>> If any of the SQL fails, then all the DB transactions are rolled back.
> >>
> >> If two databases are being used, and the commit to the first succeeds
> >> and the commit to the second fails, how does it "rollback" the first 
> >> commit?
> >
> > Depending on the reason for failure, it could still be done when using 
> > something like a two-phase commit protocol.  This isn't a 100% solution, 
> > but for the situations where it works you don't need to undo the succeeding 
> > databases. -- Darren Duncan
> 
> I know. I was just asking a leading question to draw out the issue ;-)
> 
> My point was the UR doesn't actually do what it was described as doing:
> "If any of the SQL fails, then all the DB transactions are rolled back."
> David as agreed in a folowup message.

Just to clarify a bit, if any of the executed SQL (prepares, executes,
dos, etc.) fails during a transaction, all transactions are rolled
back.  If the commit fails, which, in our experience, is a rare event
and typically indicative of some other issue with the database (e.g.,
heavy load causing slowness and large rollback segments), then an
error is returned.

-- 
David Dooling
http://www.politigenomics.com/

Reply via email to