@@ -120,25 +120,18 @@ renderTransactionMode mode =
120-- between concurrent transactions, which must not occur at each level.
120-- between concurrent transactions, which must not occur at each level.
121-- The phenomena which are prohibited at various levels are:
121-- The phenomena which are prohibited at various levels are:
123−-- __Dirty read__
123+-- __Dirty read__: A transaction reads data written by a concurrent uncommitted transaction.
125−-- A transaction reads data written by a concurrent uncommitted transaction.
127−-- __Nonrepeatable read__
129−-- A transaction re-reads data it has previously read and finds that data
125+-- __Nonrepeatable read__: A transaction re-reads data it has previously read and finds that data
130-- has been modified by another transaction (that committed since the initial read).
126-- has been modified by another transaction (that committed since the initial read).
134−-- A transaction re-executes a query returning a set of rows that satisfy
128+-- __Phantom read__: A transaction re-executes a query returning a set of rows that satisfy
135-- a search condition and finds that the set of rows satisfying the condition
129-- a search condition and finds that the set of rows satisfying the condition
136-- has changed due to another recently-committed transaction.
130-- has changed due to another recently-committed transaction.
138−-- __Serialization anomaly__
140−-- The result of successfully committing a group of transactions is inconsistent
132+-- __Serialization anomaly__: The result of successfully committing a group of transactions is inconsistent
141-- with all possible orderings of running those transactions one at a time.
133-- with all possible orderings of running those transactions one at a time.
142-- In PostgreSQL, you can request any of the four standard transaction
135-- In PostgreSQL, you can request any of the four standard transaction
143-- isolation levels, but internally only three distinct isolation levels are implemented,
136-- isolation levels, but internally only three distinct isolation levels are implemented,
144-- i.e. PostgreSQL's `ReadUncommitted` mode behaves like `ReadCommitted`.
137-- i.e. PostgreSQL's `ReadUncommitted` mode behaves like `ReadCommitted`.
@@ -202,7 +195,7 @@ renderAccessMode = \case
202-- after which it is able to run without the normal overhead of a
195-- after which it is able to run without the normal overhead of a
203-- `Serializable` transaction and without any risk of contributing
196-- `Serializable` transaction and without any risk of contributing
204-- to or being canceled by a serialization failure.
197-- to or being canceled by a serialization failure.
205−-- This mode is well suited for long-running reports or backups.
198+-- This `longRunningMode` is well suited for long-running reports or backups.
206data DeferrableMode
199data DeferrableMode
207 = Deferrable
200 = Deferrable
208 | NotDeferrable
201 | NotDeferrable