Basic but good. execute will prepare the statement each time through, whereas executemany will prepare once and then just bind for each run through, which is where the time saving comes from. Depending on how complex what you're doing is though it can be hard, or more often awkward to create an iterator for executemany.
The other thing I'd add is that you can upgrade your SQLite version by replacing the sqlite3.dll file in your \pythonxx\DLLs folder and get the latest new SQLite features. Just remember that if you're then passing your script off to someone else to run that they might still have the originally installed .dll from 6 years ago and won't be able to handle new feature X. -----Original Message----- From: sqlite-users [mailto:sqlite-users-boun...@mailinglists.sqlite.org] On Behalf Of Simon Slavin Sent: Sunday, October 22, 2017 12:47 PM To: SQLite mailing list Subject: [sqlite] Article about using sqlite3 in Python I don’t know enough about Python to evaluate this, but the sqlite3 side is sound, and some readers might find it useful. <https://remusao.github.io/posts/2017-10-21-few-tips-sqlite-perf.html> Simon. _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users