"James K. Lowden" wrote...
On Wed, 23 Jul 2014 20:00:52 -0600 "Keith Medcalf" <[email protected]> wrote:BEGIN; INSERT OR REPLACE INTO LSOpenProjects SELECT * FROM client.LSOpenProjects as A WHERE A.ProjID <= 133560 AND Date != A.Date AND A.login = 'user1'; END; I presume that LSOpenProjects in both databases has a unique constraint on ProjID, Date, and login ...That BEGIN/END should be superfluous because INSERT...SELECT is a single atomic statement. Is there something about SQLite that makes it necessary, or was it just for illustrative purposes?
I learned in this list that BEGIN/END speeds up the inserts by blocking the write mode to the DB. I was getting a lot of SQLITE_BUSY and these BEGIN/END got rid of 99% of them.
jic
_______________________________________________ sqlite-users mailing list [email protected] http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

