Class SqlRedbTransaction

Namespace: redb.MSSql.Data
Assembly: redb.MSSql.dll

MS SQL Server implementation of IRedbTransaction using SqlTransaction.
Connection-scoped: parent connection automatically uses this transaction.

public class SqlRedbTransaction : IRedbTransaction, IAsyncDisposable

Inheritance

ObjectSqlRedbTransaction

Implements

Properties

IsActive

Whether transaction is still active.

public bool IsActive { get; }

StartedAt

Transaction start time.

public DateTimeOffset StartedAt { get; }

TransactionId

Transaction unique identifier.

public Guid TransactionId { get; }

Methods

CommitAsync()

Commit all changes.

public Task CommitAsync()

DisposeAsync()

Dispose transaction.

public ValueTask DisposeAsync()

RollbackAsync()

Rollback all changes.

public Task RollbackAsync()

Constructors

SqlRedbTransaction(SqlTransaction, Action)

Create new transaction wrapper.