aboutsummaryrefslogtreecommitdiffstats
path: root/guides
diff options
context:
space:
mode:
authorbogdanvlviv <bogdanvlviv@gmail.com>2016-11-10 20:42:23 +0200
committerbogdanvlviv <bogdanvlviv@gmail.com>2016-11-10 20:42:23 +0200
commit25eed41c4950a6d1596130857841ae773b52f4d0 (patch)
tree3b7ca8c757ba98ef24f228e946b26ef8638ee8fd /guides
parentcd9d6bed1bc6aeee6566eed5a5162baaeba769e6 (diff)
downloadrails-25eed41c4950a6d1596130857841ae773b52f4d0.tar.gz
rails-25eed41c4950a6d1596130857841ae773b52f4d0.tar.bz2
rails-25eed41c4950a6d1596130857841ae773b52f4d0.zip
Update guides/source/active_record_querying.md
Add info about updating locking column value Follow #26050 and #26871 [ci skip]
Diffstat (limited to 'guides')
-rw-r--r--guides/source/active_record_querying.md3
1 files changed, 3 insertions, 0 deletions
diff --git a/guides/source/active_record_querying.md b/guides/source/active_record_querying.md
index 38b1ffc4c8..31220f9be2 100644
--- a/guides/source/active_record_querying.md
+++ b/guides/source/active_record_querying.md
@@ -953,6 +953,9 @@ class Client < ApplicationRecord
end
```
+NOTE: Please note that the optimistic locking will be ignored if you update the
+locking column's value.
+
### Pessimistic Locking
Pessimistic locking uses a locking mechanism provided by the underlying database. Using `lock` when building a relation obtains an exclusive lock on the selected rows. Relations using `lock` are usually wrapped inside a transaction for preventing deadlock conditions.