[Qt-interest] 答复: QTableView with summary footer
pengliang(彭亮)
pengliang at founder.com
Wed Sep 7 11:26:43 CEST 2011
Hi All
Please see the snippets and output.
Why QSqlQuery execute is true, but query.isValid is false?
How can I get the error information?
-------------------- snippets
QString str;
str = "SELECT * FROM kblive.dbo.View_PI_在站工单查询";
QSqlQuery query;
qDebug() << "exec: " << query.exec(str);
qDebug() << "query.isValid: " << query.isValid();
qDebug() << "query.lastError: " << query.lastError().isValid();
---------------- output
exec: true
query.isValid: false
query.lastError: false
More information about the Qt-interest-old
mailing list