BeginTransaction Method

Returns a transaction object. Commands associated with a transaction object are executed as a single transaction. The transaction is terminated with a Commit() or Rollback().

Syntax 1

AseTransaction BeginTransaction( )

Syntax 2

AseTransaction BeginTransaction( IsolationLevel isolationLevel )

Parameters

Return Value

An object representing the new transaction.

Usage

To associate a command with a transaction object, use the AseCommand.Transaction property.

Example

AseTransaction tx = conn.BeginTransaction(IsolationLevel.ReadUncommitted );

See the Adaptive Server Enterprise System Administration Guide for information about inconsistencies.

Related concepts
Transaction Processing
Related reference
Commit Method
Rollback Method