SqlTransaction class abstract

An abstract base class for transaction-scoped SQL operations.

Mirrors the placeholder-aware SQL building of SqlDatabase but for use inside a DbTransaction. Subclasses implement rawQuery and declare their paramStyle.

Implemented types
Available extensions

Constructors

SqlTransaction()

Properties

hashCode → int
The hash code for this object.
no setterinherited
paramStyle → DbParamStyle
The SQL parameter placeholder style used by this executor.
no setteroverride
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

delete(String table, {required Map<String, dynamic> where}) → Future<DbResult>
override
insert(String table, Map<String, dynamic> data) → Future<DbResult>
override
insertBatch(String table, List<Map<String, dynamic>> rows) → Future<DbResult>
Inserts multiple rows into table in a single batch operation.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
ph(String key) → String
query(String table) → QueryBuilder

Available on QueryExecutor, provided by the DbQueryExtension extension

Returns a QueryBuilder targeting table.
rawQuery(String query, {Map<String, dynamic>? values}) → Future<DbResult>
Executes a raw SQL statement with optional named values.
inherited
select(String table, {Map<String, dynamic>? where}) → Future<DbResult>
override
toString() → String
A string representation of this object.
inherited
update(String table, Map<String, dynamic> data, {required Map<String, dynamic> where}) → Future<DbResult>
override

Operators

operator ==(Object other) → bool
The equality operator.
inherited