Syntax: alter application clear logfile; Enable/Disable start up/auto startup In an application's properties you can set the application to start whenever the Essbase server is started
Trang 1Clear application log
A good practice for an Essbase administrator would be to clear the application log as often as possible If the application log file is allowed to get too large users, a marked decrease in system performance is seen The good news for the Essbase administrator
is that there is no need to log on to the Essbase server through EAS to clear the log
file The system administrator can write a MaxL script and use it to clear the log file
on a weekly basis Be sure to back up the log file for audit trails according to your
company's standards
Syntax:
alter application <App-Name> clear logfile;
Enable/Disable start up/auto startup
In an application's properties you can set the application to start whenever the
Essbase server is started or you can start an application at the first user request
to log on These properties can be set by the administrator with a MaxL command
startup /* Allow user to start Application */
If startup is enabled, the users can start the application upon log on If startup
is set to disabled, the users will not be able to log on, if the application is not
already started
Syntax:
alter application <App-Name> enable startup;
alter application <App-Name> disbale startup;
autostartup /* Start Application when Essbase Analytical Server
starts */
If autostartup is enabled, the application will start as soon as the Essbase analytic
server is started If autostartup is disabled, the application will not start when
the Essbase analytic server is started
Syntax:
alter application <App-Name> enable autostartup;
alter application <App-Name> disable autostartup;
Trang 2The MaxL alter statements are some of the more commonly used MaxL statements
Do not let this give you any indication as to the usefulness of every single available MaxL command You may go for years and never use a command that someone else uses every day As an Essbase administrator it is upto you to decide what works best
in your individual situation
Display application
This statement displays all of the information about all of the applications on
the server or you can specify a specific application
Syntax:
display application all;
display application <app-name>;
Drop application
The drop application command will drop an empty application To remove an
application that has databases in it, use the cascade option and if some of the objects are locked, then you can use the force option
Syntax:
drop application <App-Name> cascade;
drop application <App-Name>cascade force;
Working with an Essbase database from MaxL
In the Database MaxL object, you can use the same verbs like Alter, Create, Display, and Drop as you have used in the alter application statements, but these are at the
database level
Just like the MaxL statements that are used for altering an Essbase application,
there are many MaxL commands that are used to alter an Essbase database as well
And, just like the application level MaxL commands, the database level commands
directly correspond to the settings available to you through the EAS tool
Trang 3As you are reading through the examples we have used in the following section,
keep in mind the details from the following screenshot that shows the Database
Properties screen.
Let's see how each of these MaxL verbs will be used in the Essbase database object
Creating or replacing a database
Using a MaxL statement you can create a new standard database or a new
currency database With the create statement you can also make a copy of
an existing database
Syntax:
This statement is for a standard Essbase database:
create database <app-name.db-name>;
This statement is for a currency Essbase database:
Trang 4Code Sample:
create database 'ESSCAR'.'ESSNEW';
replace database 'ESSCAR'.'ESSBKP' as 'ESSCAR'.'ESSCAR';
or
create database 'ESSCAR'.'ESSBKP' as 'ESSCAR'.'ESSCAR';
Altering a database
Just like the application alter command there is an alter command for the databases How about we walk through some of the more commonly used ALTER commands?
Enable/Disable commands
These MaxL commands are used to enable or disable some of the more commonly
updated Essbase database properties
This syntax shows how to enable/disable Essbase database properties:
alter database <Dbs-name> enable | disable two_pass_calc |
aggregate_missing | startup | autostartup | compression >;
Code Sample:
alter database 'ESSCAR'.'ESSCAR' enable autostartup;
alter database 'ESSCAR'.'ESSCAR' enable two_pass_calc;
alter database 'ESSCAR'.'ESSCAR' disable startup;
alter database 'ESSCAR'.'ESSCAR' disable aggregate_missing;
alter database 'ESSCAR'.'ESSCAR' enable autostartup;
Archive commands
An Essbase database can be archived to a file These MaxL commands are used for
archiving a database Use the begin archive to file to begin the archive export
and end archive to end the archive export of the database We will talk more about archiving in the next chapter
Syntax:
alter database <db-name> begin archive to file <File-name>;
alter database end archive;
Trang 5Set commands
In MaxL, you can also use the set commands Some of the most widely used set
commands are retrieve_buffer_size,data_cache_size,index_cache_size, currency_conversion minimum permission, compression,lock_timeout,
implicit_commit_after n blocks, and many more
Some syntax and code samples are listed below for the set commands
Syntax:
alter database <Db-name> set <SET-COMMAND>;
Code Sample:
alter database 'ESSCAR'.'ESSCAR' set data_cache_size 4096;
alter database 'ESSCAR'.'ESSCAR' set retrieve_buffer_size 15360;
alter database 'ESSCAR'.'ESSCAR' set currency_database
'ESSCAR'.'ESSCURR'; /* This links a Standard database to its
currency database */
alter database 'ESSCAR'.'ESSCAR' set compression zlib;
alter database 'ESSCAR'.'ESSCAR' set note 'DATA IS UPATED on
02/08/2009';
Reset database
In MaxL, you can clear the data, LRO objects, and the entire outline in one single
statement Use extreme caution while using this command as there is no undo
function to save you
Syntax:
alter database <Db-Name> reset <all | data>;
Code Sample:
alter database 'ESSCAR'.'ESSCAR' reset all;
alter database 'ESSCAR'.'ESSCAR' reset data;
Rename database
Using the alter statement, you can also rename the database to a new name
Syntax: