PDA

View Full Version : QSqlite database lock + Delegate + QSqlQueryModel



NoRulez
13th October 2009, 12:52
Hey @all,

I'm working on an application which uses QSqlite. For this i use a QTableView, QSqlQueryModel and a Delegate.
In the Constructor of the QSqlQueryModel I create the SELECT statement and execute them.

The Delegate gives me for column 4 a QComboBox (This items are read from the database).
After the delegate has finished, i do an update on the QSqlQueryModel (UPDATE TABLE....) --> (At this point I become a "Sqlite lock error"), and refresh then the model.
Maybe at this point I become a "Sqlite lock error" too.
How can i work with Sqlite and the model/view concept?

What i'm doing wrong?

Best Regards
NoRulez