Skip to content

Commit 046fd4f

Browse files
committed
doc: clarify when row-level locks are released
They are released just like table-level locks. Also clean up wording. (Uses wording "rolled back to".) Reported-by: me@sillymon.ch Discussion: https://postgr.es/m/158074944048.1095.4309647363871637715@wrigleys.postgresql.org Backpatch-through: 9.5
1 parent 7dbe290 commit 046fd4f

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

doc/src/sgml/mvcc.sgml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1039,7 +1039,7 @@ ERROR: could not serialize access due to read/write dependencies among transact
10391039
</tip>
10401040

10411041
<para>
1042-
Once acquired, a lock is normally held till end of transaction. But if a
1042+
Once acquired, a lock is normally held until the end of the transaction. But if a
10431043
lock is acquired after establishing a savepoint, the lock is released
10441044
immediately if the savepoint is rolled back to. This is consistent with
10451045
the principle that <command>ROLLBACK</command> cancels all effects of the
@@ -1178,7 +1178,10 @@ ERROR: could not serialize access due to read/write dependencies among transact
11781178
conflicting locks on the same row, even in different subtransactions;
11791179
but other than that, two transactions can never hold conflicting locks
11801180
on the same row. Row-level locks do not affect data querying; they
1181-
block only <emphasis>writers and lockers</emphasis> to the same row.
1181+
block only <emphasis>writers and lockers</emphasis> to the same
1182+
row. Row-level locks are released at transaction end or during
1183+
savepoint rollback, just like table-level locks.
1184+
11821185
</para>
11831186

11841187
<variablelist>

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy