Small documentation fix.
Improve grammar. Remove redundant line. Original pull request #1765
This commit is contained in:
committed by
Jens Schauder
parent
ae272e2a1e
commit
5a3ceb200d
@@ -96,7 +96,7 @@ Instead, the `readOnly` flag is propagated as a hint to the underlying JDBC driv
|
||||
|
||||
Spring Data JDBC supports locking on derived query methods.
|
||||
To enable locking on a given derived query method inside a repository, you annotate it with `@Lock`.
|
||||
The required value of type `LockMode` offers two values: `PESSIMISTIC_READ` which guarantees that the data you are reading doesn't get modified and `PESSIMISTIC_WRITE` which obtains a lock to modify the data.
|
||||
The required value of type `LockMode` offers two values: `PESSIMISTIC_READ` which guarantees that the data you are reading doesn't get modified, and `PESSIMISTIC_WRITE` which obtains a lock to modify the data.
|
||||
Some databases do not make this distinction.
|
||||
In that cases both modes are equivalent of `PESSIMISTIC_WRITE`.
|
||||
|
||||
@@ -118,5 +118,3 @@ If you are using a databse with the MySQL Dialect this will result for example i
|
||||
----
|
||||
Select * from user u where u.lastname = lastname LOCK IN SHARE MODE
|
||||
----
|
||||
|
||||
Alternative to `LockMode.PESSIMISTIC_READ` you can use `LockMode.PESSIMISTIC_WRITE`.
|
||||
|
||||
Reference in New Issue
Block a user