you are viewing a single comment's thread
view the rest of the comments
[–] [S] 1 point 1 year ago (2 children)

I believe both SERIALIZABLE and REPEATABLE READ isolation levels would raise an error for this example.

And I looked this up: Postgres won't retry the transaction for you either. Though ultimately I think this a good default behavior.

  • source
  • parent
  • hideshow 2 child comments
  • [–] 2 points 1 year ago (1 child)

    Why would repeatable read raise an error? I'm a little rusty but I thought it was only serialisable that could do, and that repeatable read simply ensured that the committed writes of transaction 2 would not be read in transaction 1, so it updating over the top of 2 is fine.

  • source
  • parent
  • hideshow 1 child comment