以下成員源於類 QSqlDatabase 被棄用。 提供它們是為使舊源代碼能繼續工作。強烈建議不要在新代碼中使用它們。
(deprecated in 6.6)
QSqlQuery
|
exec (const QString & query = QString()) const |
[deprecated in 6.6]
QSqlQuery
QSqlDatabase::
exec
(const
QString
&
query
= QString()) const
This function is deprecated since 6.6. We strongly advise against using it in new code.
Executes a SQL statement on the database and returns a QSqlQuery 對象。使用 lastError () to retrieve error information. If query is empty, an empty, invalid query is returned and lastError () is not affected.
使用 QSqlQuery::exec () 代替。