Skip to content
Snippets Groups Projects
Commit 3b026a2c authored by Ben Boeckel's avatar Ben Boeckel
Browse files

vtkQtSQLQuery: avoid deprecated `QSqlDatabase::exec`

The replacement API has existed for all of Qt5 at least.
parent 91e6b30b
No related branches found
No related tags found
No related merge requests found
......@@ -81,8 +81,8 @@ bool vtkQtSQLQuery::Execute()
vtkErrorMacro("Query string must be non-null.");
return false;
}
this->Internals->QtQuery =
vtkQtSQLDatabase::SafeDownCast(this->Database)->QtDatabase.exec(this->Query);
this->Internals->QtQuery = QSqlQuery(vtkQtSQLDatabase::SafeDownCast(this->Database)->QtDatabase);
this->Internals->QtQuery.exec(this->Query);
QSqlError error = this->Internals->QtQuery.lastError();
if (error.isValid())
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment