Data Consistency And Access Options; Read Uncommitted; Read Committed - HP Neoview SQL Reference Manual

Hide thumbs Also See for Neoview SQL:
Table of Contents

Advertisement

Data Consistency and Access Options

Access options for DML statements affect the consistency of the data that your query accesses.
For any DML statement, you specify access options by using the FOR option ACCESS clause
and, for a SELECT statement, by using this same clause, you can also specify access options for
individual tables referenced in the FROM clause.
The possible settings for option in a DML statement are:

"READ COMMITTED "

"READ UNCOMMITTED "

"SERIALIZABLE or REPEATABLE READ"
"SKIP CONFLICT"
The SQL default access option for DML statements is READ COMMITTED.
The implementation for REPEATABLE READ and SERIALIZABLE access options is equivalent.
This entry uses SERIALIZABLE for purposes of illustration.
For related information about transactions, see
READ UNCOMMITTED
This option enables you to access locked data. READ UNCOMMITTED is not available for DML
statements that modify the database. It is available only for a SELECT statement.
READ UNCOMMITTED provides the lowest level of data consistency. A SELECT statement
executing with this access option is allowed to:
Read data modified by a concurrent process (sometimes referred to as dirty reads)
Read different committed values for the same item at different times or find that the item
no longer exists (sometimes referred to as nonrepeatable reads)
Read different sets of committed values satisfying the same predicate at different times
(sometimes referred to as phantoms)
READ COMMITTED
This option allows you to access only committed data.
The implementation requires that a lock can be acquired on the data requested by the DML
statement—but does not actually lock the data, thereby reducing lock request conflicts. If a lock
cannot be granted (implying that the row contains uncommitted data), the DML statement request
waits until the lock in place is released.
READ COMMITTED provides the next higher level of data consistency (compared to READ
UNCOMMITTED). A statement executing with this access option does not allow dirty reads,
but both nonrepeatable reads and phantoms are possible.
READ COMMITTED provides sufficient consistency for any process that does not require a
repeatable read capability.
READ COMMITTED is the default isolation level.
30
Introduction
Specifies that the data accessed by the DML statement
must be from committed rows.
Specifies that the data accessed by the SELECT statement
need not be from committed rows.
Specifies that the DML statement and any concurrent
process (accessing the same data) execute as if the
statement and the other process had run serially rather
than concurrently.
Allows transactions to skip rows locked in a conflicting
mode by another transaction. SKIP CONFLICT cannot be
used in a SET TRANSACTION statement.
"Transaction Isolation Levels" (page
36).

Advertisement

Table of Contents
loading

Table of Contents