IGNORE LIMBO
This flag is used to signal that records created by limbo transactions are to be ignored.Transactions are left “in limbo” if the second stage of a two-phase commit fails.
Note
|
Historical Note
|
IGNORE LIMBO
This flag is used to signal that records created by limbo transactions are to be ignored.Transactions are left “in limbo” if the second stage of a two-phase commit fails.
Note
|
Historical Note
|
RESERVING
The RESERVING
clause in the SET TRANSACTION
statement reserves tables specified in the table list.Reserving a table prevents other transactions from making changes in them or even, with the inclusion of certain parameters, from reading data from them while this transaction is running.
A RESERVING
clause can also be used to specify a list of tables that can be changed by other transactions, even if the transaction is started with the SNAPSHOT TABLE STABILITY
isolation level.
One RESERVING
clause is used to specify as many reserved tables as required.
RESERVING
ClauseIf one of the keywords SHARED
or PROTECTED
is omitted, SHARED
is assumed.If the whole FOR
clause is omitted, FOR SHARED READ
is assumed.The names and compatibility of the four access options for reserving tables are not obvious.
|
SHARED READ |
SHARED WRITE |
PROTECTED READ |
PROTECTED WRITE |
SHARED READ |
Yes |
Yes |
Yes |
Yes |
SHARED WRITE |
Yes |
Yes |
No |
No |
PROTECTED READ |
Yes |
No |
Yes |
No |
PROTECTED WRITE |
Yes |
No |
No |
No |
The combinations of these RESERVING
clause flags for concurrent access depend on the isolation levels of the concurrent transactions:
SNAPSHOT
isolation
Concurrent SNAPSHOT
transactions with SHARED READ
do not affect one other’s access
A concurrent mix of SNAPSHOT
and READ COMMITTED
transactions with SHARED WRITE
do not affect one another’s access, but they block transactions with SNAPSHOT TABLE STABILITY
isolation from either reading from or writing to the specified table(s)
Concurrent transactions with any isolation level and PROTECTED READ
can only read data from the reserved tables.Any attempt to write to them will cause an exception
With PROTECTED WRITE
, concurrent transactions with SNAPSHOT
and READ COMMITTED
isolation cannot write to the specified tables.Transactions with SNAPSHOT TABLE STABILITY
isolation cannot read from or write to the reserved tables at all.
SNAPSHOT TABLE STABILITY
isolation
All concurrent transactions with SHARED READ
, regardless of their isolation levels, can read from or write (if in READ WRITE
mode) to the reserved tables
Concurrent transactions with SNAPSHOT
and READ COMMITTED
isolation levels and SHARED WRITE
can read data from and write (if in READ WRITE
mode) to the specified tables but concurrent access to those tables from transactions with SNAPSHOT TABLE STABILITY
is blocked whilst these transactions are active
Concurrent transactions with any isolation level and PROTECTED READ
can only read from the reserved tables
With PROTECTED WRITE
, concurrent SNAPSHOT
and READ COMMITTED
transactions can read from but not write to the reserved tables.Access by transactions with the SNAPSHOT TABLE STABILITY
isolation level is blocked.
READ COMMITTED
isolation
With SHARED READ
, all concurrent transactions with any isolation level can both read from and write (if in READ WRITE
mode) to the reserved tables
SHARED WRITE
allows all transactions in SNAPSHOT
and READ COMMITTED
isolation to read from and write (if in READ WRITE
mode) to the specified tables and blocks access from transactions with SNAPSHOT TABLE STABILITY
isolation
With PROTECTED READ
, concurrent transactions with any isolation level can only read from the reserved tables
With PROTECTED WRITE
, concurrent transactions in SNAPSHOT
and READ COMMITTED
isolation can read from but not write to the specified tables.Access from transactions in SNAPSHOT TABLE STABILITY
isolation is blocked.
Note
|
In Embedded SQL, the |
COMMIT
Commits a transaction
DSQL, ESQL
COMMIT [TRANSACTION tr_name] [WORK] [RETAIN [SNAPSHOT] | RELEASE];
Parameter | Description |
---|---|
tr_name |
Transaction name.Available only in ESQL |
The COMMIT
statement commits all work carried out in the context of this transaction (inserts, updates, deletes, selects, execution of procedures).New record versions become available to other transactions and, unless the RETAIN
clause is employed, all server resources allocated to its work are released.
If any conflicts or other errors occur in the database during the process of committing the transaction, the transaction is not committed, and the reasons are passed back to the user application for handling, and the opportunity to attempt another commit or to roll the transaction back.
The TRANSACTION
and RELEASE
clauses are only valid in ESQL.