When I had problem with SQLite telling me that it thought the database/table was locked, it was mostly always a problem with queries that overstayed their welcome.
My tip is, either let the query run out of scope when you do not need it anymore, or insert this little line after every SELECT (where you do not loop through ".next()" anyways)
The reason is that the QtSql/Sqlite combination frees its internal result block only after the last next() has been reached.
But could you please post the complete error message?
Now for the not saving:
Are you sure you do not have a transaction started somewhere that never is commited? I must say I never had that kind of problem...




Reply With Quote
Bookmarks