On Wed, May 19, 2021 at 12:27 AM 李可强 <52194501011(at)stu(dot)ecnu(dot)edu(dot)cn> wrote:
> There is no need to return the old version written by committed transactions. The query result fo Session B is very confusing!
FWIW I think that it's a matter of how the standard is interpreted.
You expect something that Kyle Kingsbury called "Adya repeatable
read". This interpretation of RR allows an application which only
accesses records by primary key to get serializable execution.
Essentially, the primary key is special in a system that uses
traditional two-phase locking (or something closer to it than the
Postgres model). But a predicate on the PK is not special in Postgres.
--
Peter Geoghegan