Databases Reference
In-Depth Information
Once you have added your error checking, your fledgling script should look like
the script below:
OUTPUT 1 "c:\EssCmd.log"; /* The 1 specifies turning job log output
on and then you code the log's
location */
IFERROR "ERROR"; /* On an error the script will branch to the
"ERROR" line */
LOGIN hostNode userName password; /* Connect to Essbase server */
IFERROR "ERROR"; /* On an error the script will branch to the
"ERROR" line */
SELECT appName dbName; /* Connect to specific application|database */
IFERROR "ERROR"; /* On an error the script will branch to the
"ERROR" line */
*** Add functional commands here ***
OUTPUT 3; /* Turns off script logging */
LOGOUT; /* Logs out the script and exits */
:ERROR /* On an error the script branches to here and
resumes execution */
EXIT; /* In this case we exit the script */
Adding some functional commands
So now you have an EssCmd script that when executed, will turn on logging, log in
to a specified Essbase server, select a specified Essbase Application|Database, turn
off logging, and log out, all the while checking for errors in the command execution.
You now need to add some commands to the script which will actually do some work!
How about if we load a specific Essbase application and database into memory? We
will then run the default calculation script against that database. Next, we will unload
the database and the application from server memory to conserve system resources.
And finally, we will log out and the script will terminate.
To the example script above, we want to add the following commands:
LOADAPP appName; /* Loads the specified application into memory */
IFERROR "ERROR"; /* On an error the script will branch to the
"ERROR" line */
LOADDB appName dbName; /* Loads the specified database into memory */
IFERROR "ERROR"; /* On an error the script will branch to the
"ERROR" line */
 
Search WWH ::




Custom Search