[Qt-interest] qt connect sql server
André Somers
andre at familiesomers.nl
Wed Sep 7 13:40:17 CEST 2011
You might want to try actually setting some SQL in the query?
Andre
2011/9/7 pengliang(彭亮) <pengliang at founder.com>
> Hi All****
>
> Please see the snippets.****
>
> Why query.exec(str) print true, query.isValid print false? Why?
> And query.lastError print false;****
>
> How do I know what is problem ,why query.isValid print false?****
>
> ** **
>
> ** **
>
> ** **
>
> QSqlQuery query;****
>
> qDebug() << "exec: " << query.exec(str);****
>
> qDebug() << "query.isValid: " << query.isValid();****
>
> qDebug() << "query.lastError: " << query.lastError().isValid();****
>
> ** **
>
> ** **
>
> exec: true ****
>
> query.isValid: false ****
>
> query.lastError: false****
>
> ** **
>
> ** **
>
> ** **
>
> ** **
>
> thanks****
>
> ken****
>
> ** **
>
> ** **
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at qt.nokia.com
> http://lists.qt.nokia.com/mailman/listinfo/qt-interest
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20110907/ab48b392/attachment.html
More information about the Qt-interest-old
mailing list