EssCalcFile() executes a calc script against the active database from a file.
ESS_FUNC_M EssCalcFile (hDestCtx, hSrcCtx, AppName, DbName, FileName, Calculate);
ESS_HCTX_T | hDestCtx |
ESS_HCTX_T | hSrcCtx |
ESS_STR_T | AppName |
ESS_STR_T | DbName |
ESS_STR_T | FileName |
ESS_BOOL_T | Calculate |
hDestCtx | Essbase API context handle of target database on the server. |
HSrcCtx | Essbase API context handle for calc script file location. The calc script file can reside on the client or on the same server as the target database. |
AppName | Application name for calc script file location. |
DbName | databasename for calc script file location. |
FileName | Name of calc script file. |
Calculate | Controls calculation of the calc script. If TRUE, the calc script is executed. |
None.
This function requires the caller to have calc privilege (ESS_PRIV_CALC) to the active database.
ESS_FUNC_M ESS_CalcFile (ESS_HCTX_T hCtx) { ESS_FUNC_M sts = ESS_STS_NOERR; ESS_SHORT_T isResponse; ESS_HCTX_T hSrcCtx; ESS_BOOL_T isObject = ESS_FALSE; ESS_STR_T AppName; ESS_STR_T DbName; ESS_STR_T FileName; ESS_PROCSTATE_T pState; hSrcCtx = hCtx; AppName = "Sample"; DbName = "Basic"; FileName = "Test"; sts = EssCalcFile (hCtx, hSrcCtx, AppName, DbName, FileName, ESS_TRUE); if (!sts) { sts = EssGetProcessState (hCtx, &pState); while (!sts || (pState.State != ESS_STATE_DONE)) sts = EssGetProcessState (hCtx, &pState); } return(sts); }
EssBeginCalc()
EssCalc()
EssDefaultCalc()
EssSetDefaultCalcFile()