Class: BunSQLiteTransaction
Defined in: transaction.ts:14
A transaction opened by the adapter. Prisma issues BEGIN itself and then calls commit/rollback here, so this type owns only the closing statement and the write lock it inherited from the adapter.
Extends
BunSQLiteQueryable
Implements
Transaction
Properties
provider
readonly provider: "sqlite" = 'sqlite';
Defined in: queryable.ts:21
Implementation of
Transaction.provider
Inherited from
BunSQLiteQueryable.provider
adapterName
readonly adapterName: "prisma-sqlite-bun-adapter" = ADAPTER_NAME;
Defined in: queryable.ts:22
Implementation of
Transaction.adapterName
Inherited from
BunSQLiteQueryable.adapterName
options
readonly options: TransactionOptions;
Defined in: transaction.ts:18
Transaction options.
Implementation of
Transaction.options
Methods
queryRaw()
queryRaw(query): Promise<SqlResultSet>;
Defined in: queryable.ts:57
Execute a query and return its result.
Parameters
| Parameter | Type |
|---|---|
query | SqlQuery |
Returns
Promise<SqlResultSet>
Implementation of
Transaction.queryRaw
Inherited from
BunSQLiteQueryable.queryRaw
executeRaw()
executeRaw(query): Promise<number>;
Defined in: queryable.ts:92
Execute a query and return the number of affected rows.
Parameters
| Parameter | Type |
|---|---|
query | SqlQuery |
Returns
Promise<number>
Implementation of
Transaction.executeRaw
Inherited from
BunSQLiteQueryable.executeRaw
commit()
commit(): Promise<void>;
Defined in: transaction.ts:47
Commit the transaction.
Returns
Promise<void>
Implementation of
Transaction.commit
rollback()
rollback(): Promise<void>;
Defined in: transaction.ts:53
Roll back the transaction.
Returns
Promise<void>
Implementation of
Transaction.rollback
createSavepoint()
createSavepoint(name): Promise<void>;
Defined in: transaction.ts:59
Creates a savepoint within the currently running transaction.
Parameters
| Parameter | Type |
|---|---|
name | string |
Returns
Promise<void>
Implementation of
Transaction.createSavepoint
rollbackToSavepoint()
rollbackToSavepoint(name): Promise<void>;
Defined in: transaction.ts:63
Rolls back transaction state to a previously created savepoint.
Parameters
| Parameter | Type |
|---|---|
name | string |
Returns
Promise<void>
Implementation of
Transaction.rollbackToSavepoint
releaseSavepoint()
releaseSavepoint(name): Promise<void>;
Defined in: transaction.ts:67
Releases a previously created savepoint. Optional because not every connector supports this operation.
Parameters
| Parameter | Type |
|---|---|
name | string |
Returns
Promise<void>
Implementation of
Transaction.releaseSavepoint