I have not had to deal with Oracle but I think you can just :
qint32 historyid;
query.setForwardOnly(true);
query.prepare(" SELECT tracdba.proj_pkg.change_project(:rojid,:ver,:reaso n)");
query.bindValue(":rojid", versioninfo.ProjectID );
query.bindValue(":ver",versioninfo.projectVersion );
query.bindValue(":reason", versioninfo.Reason);
if(!query.exec())
{
qDebug()<< "DATABASE ERROR!!"<< query.lastError().databaseText();
return "db_Exec_Failed";
}
if( !query.next() )
return "some_error_code";
historyid = query.record().value(0).toInt();
qint32 historyid;
QSqlQuery query;
query.setForwardOnly(true);
query.prepare(" SELECT tracdba.proj_pkg.change_project(:rojid,:ver,:reaso n)");
query.bindValue(":rojid", versioninfo.ProjectID );
query.bindValue(":ver",versioninfo.projectVersion );
query.bindValue(":reason", versioninfo.Reason);
if(!query.exec())
{
qDebug()<< "DATABASE ERROR!!"<< query.lastError().databaseText();
return "db_Exec_Failed";
}
if( !query.next() )
return "some_error_code";
historyid = query.record().value(0).toInt();
To copy to clipboard, switch view to plain text mode
Bookmarks