- Notifications
You must be signed in to change notification settings - Fork83
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
-
I'd like to optimize performance for batch insert operations, for example when a database is restored from JSON dump (say 1000 INSERT statements are run). I'm using OPFSCoopSyncVFS + sync build in a worker. I have the following questions:
Is there anything else I'm missing for optimizing batch inserts? Python has a special commandexecutemany(), but I haven't seen an analogue of this in either node's better-sqlite3 nor in wa-sqlite. I guess, outside of a special C-level batch insert function, our best bet is wrapping it in a transaction or savepoint? |
BetaWas this translation helpful?Give feedback.
All reactions
Replies: 1 comment
-
FYI, I have never had a need for a nested transaction so I have only played briefly with savepoints. Answers:
I coincidentally posted adrive-by response about this last week. |
BetaWas this translation helpful?Give feedback.