This commit is contained in:
Kane Wang 2020-03-15 21:03:58 +08:00
parent dedb1e0b34
commit 6227880fdb
1 changed files with 13 additions and 0 deletions

View File

@ -172,6 +172,9 @@ void ImportRepairOrderToOracle( std::string userName,
std::string tnsName,
std::vector<RepairOrder> & orderVector )
{
OCI_Connection* pConn = nullptr;
OCI_Statement* pStmt = nullptr;
int returnCode = 0;
const otext * szSqlImport =
"BEGIN"
" car_dealer.dat:a_import_util_pkg.import_repairing_order(:a_branch_name,"
@ -203,4 +206,14 @@ void ImportRepairOrderToOracle( std::string userName,
"END;";
//初始化
returnCode = OCI_Initialize(l_error_handler, nullptr, OCI_ENV_DEFAULT);
if ( returnCode == false )
{
string errorMessage("ocilib初始化错误:");
errorMessage.append(get_last_error_message());
throw runtime_error(errorMessage);
}
}