File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -188,8 +188,9 @@ SQLite has a limit for attached databases: A default of 10, and a global max of
188188SQLite docs for [ Attach] ( https://www.sqlite.org/lang_attach.html ) - [ Detach] ( https://www.sqlite.org/lang_detach.html )
189189
190190``` tsx
191+ // Follows similar API to the `open` call
191192db .attach ({
192- secondaryDbFileName: ' statistics.sqlite' , // Just the filename of the database
193+ secondaryDbFileName: ' statistics.sqlite' , // Filename of the database (JUST THE FILENAME)
193194 alias: ' stats' , // Alias to be applied to the db
194195 location: ' ../databases' , // Path to be prepended to secondaryFileName, in this case full db path: ../databases/statistics.sqlite
195196});
@@ -200,10 +201,6 @@ const res = await db.execute(
200201
201202// You can detach databases at any moment
202203db .detach (' stats' );
203-
204- if (! detachResult .status ) {
205- // Database de-attached
206- }
207204```
208205
209206## Loading SQL Dump Files
You can’t perform that action at this time.
0 commit comments