mirror of
https://github.com/groue/GRDB.swift
synced 2026-11-30 04:28:44 +00:00
README.md
This commit is contained in:
1 parent
059af3a621
commit
17b43d021a
1 file changed
+2
-1
@@ -1041,11 +1041,12 @@ try dbQueue.inDatabase { db in // or dbPool.write { db in
|
||||
}
|
||||
```
|
||||
|
||||
SQLite supports [three kinds of transactions](https://www.sqlite.org/lang_transaction.html): DEFERRED, IMMEDIATE, and EXCLUSIVE. GRDB defaults to IMMEDIATE.
|
||||
SQLite supports [three kinds of transactions](https://www.sqlite.org/lang_transaction.html): deferred, immediate, and exclusive. GRDB defaults to immediate.
|
||||
|
||||
The transaction kind can be changed in the database configuration, or for each transaction:
|
||||
|
||||
```swift
|
||||
// A connection with default DEFERRED transactions:
|
||||
var config = Configuration()
|
||||
config.defaultTransactionKind = .Deferred
|
||||
let dbQueue = try DatabaseQueue(path: "...", configuration: config)
|
||||
|
||||
Reference in new issue
Block a user