>I think that operation will go MUCH faster if you (1) turn off >auto_vacuum, (2) use journal_mode=DELETE, and (3) put all of the >DELETE operations inside a single transaction. > >D. Richard Hipp
I have used auto_commit as a replacement for vacuum. Because I only add new data and only delete from the end I thought it would be faster (no extra scan to rebuild ). I use WAL mode to not block the reader processes. Do you suggest I should switch to delete mode before I really delete data and switch to wal back after I'm done? I have a prepared statement "delete from tablename" for each table. I start a transaction and for each table I do sqlite3_reset() and sqlite3_step(). After this I end the transaction. Should I place all the delete statements in a single statement? Thank you Rene BTW. Will you be at the eurotcl conference? Kernkraftwerk Goesgen-Daeniken AG CH-4658 Daeniken, Switzerland Diese Nachricht (inkl. Anhaenge) beinhaltet moeglicherweise vertrauliche oder gesetzlich geschuetzte Daten oder Informationen. Zum Empfang derselben ist (sind) ausschliesslich die genannte(n) Person(en) bestimmt. Falls Sie diese Nachricht irrtuemlicherweise erreicht hat, sind Sie hoeflich gebeten, diese unter Ausschluss jeder Reproduktion zu vernichten und den Absender umgehend zu benachrichtigen. Besten Dank.