EssValidateDB

Description

EssValidateDB() checks the database for data integrity.

Syntax

ESS_FUNC_M EssValidateDB (hCtx, DbName, FileName);
ESS_HCTX_ThCtx
ESS_STR_TDbName
ESS_STR_TFileName

Parameters

hCtxEssbase API context handle.
DbNameDatabase name. Required, cannot be NULL.
FileNameError log file name, to be placed in the app\db directory on the server. Required.

Return Value

None.

Notes

Access

This function requires the caller to have Database Design privilege (ESS_PRIV_DBDESIGN) for the specified database.

Example

ESS_VOID_T 
ESS_ValidateDB (ESS_HCTX_T hCtx)
{
   ESS_FUNC_M        sts = ESS_STS_NOERR;  
   ESS_STR_T        DbName;
   ESS_STR_T        FileName;  
   ESS_PROCSTATE_T  pState; 
   
   DbName   = "Basic";
   FileName =   
    "D:\\Essbase\\app\\sample\\basic\\Validate.lst";
   
   sts = EssValidateDB (hCtx, DbName, FileName);
   
   if (!sts)
   {
      sts = EssGetProcessState (hCtx, &pState);
      while (!sts || (pState.State !=
              ESS_STATE_DONE))
        sts = EssGetProcessState (hCtx, &pState);      
   }
}

See Also

EssSetActive()
EssGetProcessState()