Repeatable read isolation level
Repeatable read is a database transaction-isolation level that prevents a transaction from observing changes to data it has already read during that transaction.
Java Persistence with Spring Data and Hibernate epub
Repeatable read is a transaction isolation level under which repeated reads of the same data return a consistent value within a transaction, preventing unrepeatable reads while generally allowing phantom reads.
- How it is used
- Protects repeated reads within a transaction and frames the choice of database isolation for concurrent application work.
- How deep it goes
- Compares prevented anomalies, costs, and related JPA locking behavior, without specifying a database's internal isolation algorithm.
- Examples
- Uses an isolation-level comparison, a locked item-price calculation, and a MySQL JDBC setting for refresh visibility.
- What you can do after
- Operate/configure it to preserve repeated row reads and adjust isolation when refresh must see another transaction's changes.
100 SQL Server Mistakes and How to Avoid Them
Repeatable Read is a transaction isolation level that prevents dirty and nonrepeatable reads but can allow phantom reads.
- How it is used
- Guides transaction-isolation choices when preventing nonrepeatable reads matters more than permitting maximum concurrency.
- How deep it goes
- Explains dirty, nonrepeatable, and phantom reads through concurrent transactions, but stops short of implementation internals.
- Examples
- Demonstrates reporting queries and a data steward's updates or deletes against ImpressionsArchive in two query windows.
- What you can do after
- Evaluate whether Repeatable Read is necessary, then choose a weaker or stronger isolation level according to consistency and contention requirements.
Read how 100 SQL Server Mistakes and How to Avoid Them explains repeatable read isolation level →
Related concepts
- isolationkind of · Isolation is the separation of components, processes, resources, or contexts to limit interaction, interference, or the propagation of effects between them.
- nonrepeatable readaddresses · A nonrepeatable read is a concurrency anomaly in which repeated reads of the same data within a transaction return different values after another transaction modifies it.
- MySQLconfigured by · MySQL is an open-source relational database management system that stores, manages, and queries structured data using SQL.
- PESSIMISTIC_WRITEproduced by · PESSIMISTIC_WRITE is a JPA lock mode that acquires an exclusive lock, guarantees repeatable reads, and serializes conflicting data access.
- database transactionconfigures · A database transaction is a logical unit of database operations whose changes are committed together or rolled back as a whole.
- read committed isolation levelcontrasts with · A database transaction isolation level that prevents reads of uncommitted changes while allowing later reads in a transaction to observe newer committed data.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.

