withManualTransactions
withManualTransactions(
adapter,exec):DatabaseAdapter
Defined in: packages/db-sqlite/src/drizzle-factory.ts:27
Wrap an adapter with manual BEGIN/COMMIT transactions for synchronous
SQLite drivers (better-sqlite3, bun:sqlite), whose transaction()
rejects async callbacks. Statements run on the adapter’s own connection,
so the open transaction covers them; rollback runs on throw.
Parameters
Section titled “Parameters”adapter
Section titled “adapter”DatabaseAdapter
Adapter built by createDrizzleAdapter.
(sql) => void
Synchronous statement runner on the same connection.
Returns
Section titled “Returns”DatabaseAdapter
The adapter with transact replaced.