Re: Strange Behavior with Serializable Transcations

From: Simon Riggs <simon(at)2ndquadrant(dot)com>
To: Martijn van Oosterhout <kleptog(at)svana(dot)org>
Cc: Brad Nicholson <bnichols(at)ca(dot)afilias(dot)info>, pgsql-general(at)postgresql(dot)org
Subject: Re: Strange Behavior with Serializable Transcations
Date: 2006-06-29 12:43:10
Message-ID: 1151584990.2749.16.camel@localhost.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Thu, 2006-06-29 at 14:27 +0200, Martijn van Oosterhout wrote:
> On Thu, Jun 29, 2006 at 01:21:19PM +0100, Simon Riggs wrote:
> > The issue is the difference between start of transaction and time when
> > the serializable snapshot is taken. Since BEGIN and other commands may
> > be issued as separate network requests it makes sense to defer taking
> > the snapshot until the first time it is needed. The transaction is still
> > serializable, just that the manual is worded slightly incorrectly with
> > regards the exact timing.
>
> I've always interpreted it as "there exists a serialised order for the
> transactions" but the database makes no guarentees about what it might
> be. I can't think of any real world case where you actually care about
> the order, just as long as one exists.

Agreed, the ordering is irrelevant.

Deferring the snapshot provides you with the most accurate *and*
consistent view of the database.

--
Simon Riggs
EnterpriseDB http://www.enterprisedb.com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Alain Roger 2006-06-29 12:44:59 PHPpgadmin and user privileges
Previous Message Alvaro Herrera 2006-06-29 12:39:50 Re: User privileges in web database applications