dotConnect for DB2 Documentation
Devart.Data.DB2 Namespace / DB2Connection Class / EnlistDistributedTransaction Method
A reference to an existing transaction in which to enlist.

In This Topic
EnlistDistributedTransaction Method
In This Topic
Enlists in the specified transaction as a distributed transaction.
Syntax
'Declaration
 
Public Sub EnlistDistributedTransaction( _
   ByVal transaction As ITransaction _
) 
 

Parameters

transaction
A reference to an existing transaction in which to enlist.
Remarks
EnlistDistributedTransaction returns an exception if the DB2Connection has already started a transaction using BeginTransaction. However, if the transaction is a local transaction started at the data source (for example, by explicity executing the BEGIN TRANSACTION statement using a DB2Command object), EnlistDistributedTransaction rolls back the local transaction and enlists in the existing distributed transaction as requested. You will not receive notice that the local transaction was rolled back, and are responsible for managing any local transactions not started using BeginTransaction.
See Also