We have a Microsoft Excel file as our data source so we have selected the Data files option.. Click on the Find Rules File and select the rule file that you have built and saved on the
Trang 1As you can see from the previous screen, you would be able to select either the
SQL data source or the Data Files If you choose to select SQL, then you will need
to provide the SQL user name and SQL password
1 We have a Microsoft Excel file as our data source so we have selected
the Data files option.
2 Click on the Find Data File Browse through the directory and select
the data source file You have the choice of a local file or a server file
3 Click on the Find Rules File and select the rule file that you have built
and saved on the server
4 For the error file, you can give a different error file path and name, or you
can use the default error file If you think the error file already exists, please
select the option Overwrite If not, you will get an error message.
5 Click on OK.
6 Essbase will load the data per the instructions in the rules file you selected
If it is a dimension build rules file (as is this case), the outline itself will
be updated
7 The outline will be updated, saved, and restructured The new outline
is shown in the following screenshot:
Trang 2Update using MaxL Shell
In the earlier versions of Essbase, EssCmd (Essbase Command Script) was
widely used as the shell script of choice In the newer versions of Essbase, Oracle
recommends using MaxL Shell scripts Using the MaxL Shell statements, you will
be able to perform most of the Essbase functions like dimension building, importing data, and calculating data
A MaxL Shell script can be executed three different ways:
• Through the EAS editor
• From the DOS Command Line
• Shelled from within another scripting language
Executing MaxL from EAS editor
The steps to execute MaxL from EAS editor are:
1 Within EAS, click on File |Editor | MaxL Script Editor
2 The MaxL editor will be opened as shown in the screenshot below:
• In the MaxL editor, you can write a MaxL statement and then execute it
MaxL is the multidimensional database access language for Essbase analytic services MaxL is an easy to use interface for Essbase database administration
The IMPORT DIMENSION statement would be used to build the outline The syntax in the example MaxL statement shows when we use a data file to update the dimension
Trang 3Syntax of Import Dimension statement
We will show you some actual code that can be used in the MaxL editor to execute
database commands As we will present in much greater detail later in this book,
MaxL is a command-based scripting language that you can use for automating
maintenance and routine tasks:
IMPORT DATABASE APPLICATION NAME.DATABASE NAME DIMENSIONS
FROM (input data file information)
LOCAL | SERVER /* Location of the data file
FILE TYPE /* Type of data source whether a Text files, Excel File,
or Lotus File
DATA_FILE
FILE PATH ' Path of the file like c:/book/chapter3/rules/market.xls
USING (Information about the Rule File)
LOCAL | SERVER ' Location of the rule file
RULE_FILE
RULE FILE NAME ' Name of the rule file like Markt
ON ERROR APPEND TO (error File information)
WRITE | APPEND
ERROR File name ' Path for error file
' c:/book/DimError.log
The following screenshot shows the code that was entered into the EAS MaxL editor
and then executed by pressing the F5 button or clicking on the MaxL | Execute button:
Trang 4As shown in the previous screenshot, the script has executed without errors
Let's modify the script to force an error message
We have changed the reserve word database to data. This is a glaring syntax error
and will immediately generate an error message as shown in the following screenshot:
This script can also be saved with the extension mxl for later use
Executing MaxL from command prompt
You can use MaxL statements from the DOS command prompt as well
The essmsh.exe file is located in the $Arborpath/bin which, in our case,
is C:\Oracle\AnalyticServices\bin
From the command prompt, go to this directory and enter the word ESSMSH
as shown:
In the EAS editor, you need not log on to the Essbase server as EAS is already
connected to Essbase When using the command prompt, you need to log in
to Essbase Using the following syntax in a MaxL statement, you log in to the
Essbase server:
Login 'UserID' 'Password' on 'ServerName';
Trang 5The following is an example of logging in through the command line:
Now, that you are logged on to the Essbase server, you can execute any MaxL
statement using the command line to update the Essbase outline The following
screenshot shows how you can achieve this Notice how the syntax is very easy
to read Almost like a spoken sentence
Our Esscar outline is now updated with the new Market structure
Hooray! You have built your first outline using an Essbase rules file and you have
also learned how to execute the script manually and also by using MaxL to run a
script that uses your load rule file
Attribute dimensions
Attribute dimensions are dimensions associated with standard dimensions Attribute dimensions are useful in describing a standard dimension member's attributes For
example, in our Esscar database, we have the Vehicles dimension If we wanted
to differentiate between a two or four door car of the same model, we could use an
attribute dimension to accomplish this We could also use an attribute dimension to
track color