mirror of
https://github.com/FirebirdSQL/firebird.git
synced 2025-01-22 14:43:03 +01:00
babd741daa
* Add AUTO RELEASE TEMP BLOBID transaction option It makes the transaction release temporary ID of user BLOB just after its materialization. It's useful for massive insertions of records with user-defined BLOBs because it eliminates the memory overhead caused by creating and keeping temporary IDs until the transaction ends. This option is used during the database restore. * Place tokens in the correct sections * Avoid repeated attempts to start a transaction with options that are not supported by the target server * Correct AUTO RELEASE TEMP BLOBID description * Check bad_tpb_form error for more reliable detection of unsupported transaction options * Do not use unsupported options for transactions of parallel workers performing RestoreRelationTask
55 lines
2.1 KiB
Plaintext
55 lines
2.1 KiB
Plaintext
More options exposed in the SET TRANSACTION command.
|
|
|
|
Syntax
|
|
========
|
|
|
|
SET TRANSACTION option_list
|
|
|
|
The command is used in DSQL to start a transaction without using the specialized
|
|
API call to create a new transaction. To the already existing options, the following
|
|
have been added. Notice this is not new functionality: it's available through the
|
|
TPB since years ago (they appear in ibase.h as items for TPBs). This extension
|
|
only makes those options available to clients that want to start a transaction by
|
|
executing a DSQL command, like isql's command prompt.
|
|
|
|
The new options exposed are:
|
|
|
|
NO AUTO UNDO: prevents the transaction from keeping an undo log that would be used
|
|
to undo its changes if it's rolled back. The net effect is undoing the changes, then
|
|
marking the transaction as committed. Without the undo logs, other transactions
|
|
reading the affected record will collect the garbage. This option is useful for
|
|
massive insertions when there's no need to roll back.
|
|
|
|
IGNORE LIMBO: ignores the records created by transactions in limbo. Typically a
|
|
transaction is in limbo when it's a multi-database transaction and the two phase
|
|
commit fails. This option is mostly used by gfix.
|
|
|
|
LOCK TIMEOUT nonneg_short_integer: it's the time (measured in seconds) that a
|
|
transaction waits for a lock in a record before giving up and reporting an error.
|
|
|
|
AUTO RELEASE TEMP BLOBID: makes the transaction release a temporary ID of a user
|
|
BLOB just after its materialization. It's useful for massive insertions of records
|
|
with user-defined BLOBs because it eliminates the memory overhead caused by creating
|
|
and keeping temporary IDs until the transaction ends. This option should be used
|
|
with care and only if there is no need to access a materialized BLOB via a temporary
|
|
ID obtained after its creation. It's used during the database restore.
|
|
|
|
|
|
Author:
|
|
Claudio Valderrama C.
|
|
|
|
N O T E S
|
|
=========
|
|
|
|
1. Lock timeout has to be zero or positive and will be rejected if the NO WAIT
|
|
option is specified.
|
|
2.- For transactions that only read data, no auto undo has zero impact.
|
|
|
|
Example
|
|
=======
|
|
|
|
Using an isql session:
|
|
|
|
set transaction no auto undo lock timeout 10;
|
|
|