Just throwing out ideas here since I'm not familiar with SQLite (I'm a Python/Oracle guy myself), but does SQLite have merge and/or upsert capabilities? That's pretty quick usually.
Better yet, bulk (single transaction) inserts into a stage table which would then merge into the main table would by far be the quickest I think.
I'm sure these ideas have been already thought of (they're the norm for this kind of stuff), but like I said, thinking out loud for any patchers out there.
|