Re: More FOR UPDATE/FOR SHARE problems - Mailing list pgsql-hackers

From Kevin Grittner
Subject Re: More FOR UPDATE/FOR SHARE problems
Date
Msg-id 497D9FAE.EE98.0025.0@wicourts.gov
Whole thread Raw
In response to Re: More FOR UPDATE/FOR SHARE problems  (Jeff Davis <pgsql@j-davis.com>)
Responses Re: More FOR UPDATE/FOR SHARE problems  (Grzegorz Jaskiewicz <gj@pointblue.com.pl>)
Re: More FOR UPDATE/FOR SHARE problems  (Jeff Davis <pgsql@j-davis.com>)
List pgsql-hackers
>>> Jeff Davis <pgsql@j-davis.com> wrote: 
> In fact, it's probably most similar to UPDATE ... RETURNING, which
will
> give the same result (that breaks atomicity or isolation, depending
on
> your point of view), which is correct for READ COMMITTED isolation
> level.
READ COMMITTED is not supposed to be able to view the work of a
concurrent transactions as PARTLY applied and PARTLY committed, which
is what's happening here.  If one statement in a READ COMMITTED
transaction sees the uncommitted view of the data and the next
statement sees the committed view, that's compliant.  It may not
surprise someone who is intimately familiar with PostgreSQL internals
for a single SELECT statement to see PART of a transactions work, but
it would surprise most users, and is certainly not compliant with the
standard.
-Kevin


pgsql-hackers by date:

Previous
From: Jeff Davis
Date:
Subject: Re: More FOR UPDATE/FOR SHARE problems
Next
From: Tom Lane
Date:
Subject: Re: 8.4 release planning