You can call the commit() method of the connection object to ensure that any changes are saved to disk, but it's strictly optional. Closely/reopening is not necessary.
Cheers On Sunday 26 December 2010, Timo wrote: > Hello, I use SQLite in my application as database, but I think I'm doing > something wrong. > > Currently, I open a connection and cursor object every time I do an > operation (insert, select, update, ...) and close it afterwards. Now I was > wondering if it wouldn't be better to open the connection if my application > starts, and commit and close when the user quits. > Is this save? Can data be selected if I haven't commit anything? > > Cheers, > Timo _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor