Re: Documentation Inaccuracy – Transaction Isolation - Mailing list pgsql-general

From Bruce Momjian
Subject Re: Documentation Inaccuracy – Transaction Isolation
Date
Msg-id 20150428202334.GB31725@momjian.us
Whole thread Raw
In response to Documentation Inaccuracy – Transaction Isolation  ("Nicholson, Brad (Toronto, ON, CA)" <bnicholson@hp.com>)
List pgsql-general
On Tue, Apr 28, 2015 at 08:00:24PM +0000, Nicholson, Brad (Toronto, ON, CA) wrote:
> Hi,
>
> I noticed an inaccuracy in the transaction isolation docs.  Under the Repeatable Read Isolation Level section it
states:
>
> “The Repeatable Read isolation level only sees data committed before the transaction began; it never sees either
uncommitteddata or changes committed during transaction execution by concurrent transactions.” 
>
> That is not entirely accurate.  The snapshot starts with the first SQL statement in the transaction, not at the start
ofthe transaction.  Any change that is committed in another transaction after the start of the transaction but before
thefirst SQL statement will be seen. 

Yes, we have fixed that for PG 9.5:

    http://www.postgresql.org/docs/devel/static/transaction-iso.html

    This level is different from Read Committed in that a query in a
-->    repeatable read transaction sees a snapshot as of the start of the first
-->    non-transaction-control statement in the transaction, not as of the
    start of the current statement within the transaction. Thus, successive
    SELECT commands within a single transaction see the same data, i.e.,
    they do not see changes made by other transactions that committed after
    their own transaction started.

--
  Bruce Momjian  <bruce@momjian.us>        http://momjian.us
  EnterpriseDB                             http://enterprisedb.com

  + Everyone has their own god. +


pgsql-general by date:

Previous
From: "Nicholson, Brad (Toronto, ON, CA)"
Date:
Subject: Documentation Inaccuracy – Transaction Isolation
Next
From: Jonathan Vanasco
Date:
Subject: newsfeed type query