Oracle9i OLAP Services Developer's Guide to the OLAP DML
Release 1 (9.0.1)

Part Number A86720-01
Go To Documentation Library
Home
Go To Product List
Book List
Go To Table Of Contents
Contents
Go To Index
Index

Master Index

Feedback

Go to previous page Go to beginning of chapter Go to next page

Creating and Using Analytic Workspace Metadata, 3 of 7


Analytic Workspace Metadata Prerequisites

Required analytic workspace metadata

To create analytic workspace metadata and make the OLAP API aware that the metadata exists, you must perform both of the following steps:

  1. Define a metadata locator object.

  2. Define metadata for every OLAP DML object that you wish for the OLAP API to display.

Defining the metadata locator object: ECMLOCATOR

The metadata locator object is the first point of contact with an analytic workspace's metadata. Therefore, you must define one metadata locator object for every analytic workspace whose data you wish to display in a Java client. Once you have defined the metadata locator object, be sure to assign the ISECMLOCATOR property to it -- if you fail to do so, OLAP Services will not be able to recognize that the analytic workspace contains metadata, and the OLAP API will be unable to display any data in that workspace.

Use the DEFINE command to create a text variable named ECMLOCATOR.

For example, use the following command to define a metadata locator object:

define ECMLOCATOR variable text

Properties required by the metadata locator object

After you define ECMLOCATOR, you must then set the following properties on it:

Setting the ISECMLOCATOR property

After you define ECMLOCATOR, then use the PROPERTY command to set the ISECMLOCATOR property to YES. Note that the name of any property must be enclosed in single quotes.

If the ECMLOCATOR variable is not the current object, then use the CONSIDER command before the PROPERTY command.

For example, use the following commands to set the ISECMLOCATOR property on the ECMLOCATOR variable:

consider ECMLOCATOR
property 'ISECMLOCATOR' yes

When the OLAP API opens an analytic workspace, an attempt is made to locate an OLAP DML object that has an ISECMLOCATOR property that is set to YES. This is how the OLAP API determines that the analytic workspace contains data that is described by analytic workspace metadata.

Set the DBDIMDIM property to identify the workspace's dimensions

DBDIMDIM is a property that specifies the name of the dimension dimension, which you must define and populate. This is a dimension whose dimension values are the names of the OLAP DML dimensions that exist in the analytic workspace.

To set the DBDIMDIM property, follow these steps:

  1. Define and populate the dimension dimension.

  2. Set the required properties on the dimension dimension.

  3. Set the DBDIMDIM property on ECMLOCATOR. The DBDIMDIM property will specify the name of the dimension dimension that you have defined.

Defining the dimension dimension

Use the DEFINE DIMENSION command to define the dimension dimension. Then use the MAINTAIN command to specify the names of the dimensions that exist in the analytic workspace as the dimension values.

Suppose your analytic workspace contains three dimensions, named TIME, GEOGRAPHY, and PRODUCT. Use the following commands to define and populate a dimension named dbdimdim:

define dbdimdim dimension text
maintain dbdimdim add 'TIME' 'GEOGRAPHY' 'PRODUCT'

Setting properties on the dimension dimension

Once you have defined a dimension dimension, you then assign the following properties to it:

For each property, define the object and populate it. You can then set the property on the dimension dimension.

For example, suppose you define and populate a variable named dbdim_ldscvar, a formula named dbdim_numhierfrm, and a variable named dbdim_sdscvar. Use the following commands to set the properties on a dimension dimension named dbdimdim:

consider dbdimdim
property 'LDSCVAR' 'dbdim_ldscvar'
property 'NUMHIERFRM' 'dbdim_numhierfrm'
property 'SDSCVAR' 'dbdim_sdscvar'

Setting the DBDIMDIM property on ECMLOCATOR

Once you have defined a dimension dimension, set the DBDIMDIM property on ECMLOCATOR. The following example specifies dbdimdim as the name of the dimension dimension:

consider eclocator
property 'DBDIMDIM' 'dbdimdim'

Set the DBMEASDIM property to identify the workspace's measures

DBMEASDIM is a property that specifies the name of a measure dimension, which you must define and populate. This is a dimension whose dimension values are the names of the OLAP DML variables that you have defined in the analytic workspace.

To set the DBMEASDIM property, follow these steps:

  1. Define and populate the measure dimension.

  2. Set the required properties on the measure dimension.

  3. Set the DBMEASDIM property on ECMLOCATOR. The DBMEASDIM property will specify the name of the measure dimension that you have defined.

Defining the measure dimension

Use the DEFINE DIMENSION command to define the measure dimension. Then use the MAINTAIN command to specify the names of the variables that exist in the analytic workspace as the dimension values.

Suppose your analytic workspace contains three variables, named SALES, UNITS, and PROJECTED_SALES. You can use the following commands to define and populate a measure dimension named dbmeasdim:

define dbmeasdim dimension text
maintain dbmeasdim add 'SALES' 'UNITS' 'PROJECTED_SALES'

Setting properties on the measure dimension

The only property that you need to set for the measure dimension is the LDSCVAR property. See "Set the DBDIMDIM property to identify the workspace's dimensions" for an example of setting the LDSCVAR property.

Once you have defined a measure dimension, you then assign the following property to it:

LDSCVAR -- Specifies the name of a text variable that contains the long descriptive labels of the variables. You must define this text variable, which should be dimensioned by the dimension dimension.

First, define the object and populate it. You can then set the property on the measure dimension.

For example, suppose you define and populate a variable named dbmeas_ldscvar. Use the following commands to set the property on a dimension dimension named dbdimdim:

consider dbdimdim
property 'LDSCVAR' 'dbmeas_ldscvar'

Setting the DBMEASDIM property on ECMLOCATOR

Once you have defined a measure dimension, set the DBMEASDIM property on ECMLOCATOR. The following example specifies dbmeasdim as the name of the measure dimension:

consider ECMLOCATOR
property 'DBMEASDIM' 'dbmeasdim'

Set the DBATTRDIM property to identify the workspace's attributes

DBATTRDIM is a property that specifies the name of an attribute dimension, which you must define and populate. This is a dimension whose dimension values are the names of the OLAP DML attributes that exist in the analytic workspace.

To set the DBATTRDIM property, follow these steps:

  1. Define and populate the attribute dimension.

  2. Set the required properties on the attribute dimension.

  3. Set the DBATTRDIM property on ECMLOCATOR. The DBATTRDIM property will specify the name of the attribute dimension that you have defined.

For more information about attributes, refer to "Metadata That Describes Dimension Attributes".

Defining the attribute dimension

Use the DEFINE DIMENSION command to define the attribute dimension. Then use the MAINTAIN command to specify the names of the attributes that exist in the analytic workspace as the dimension values.

Suppose your analytic workspace contains three attributes, named USE, GENDER, and AGE. Use the following commands to define and populate a dimension named dbattrdim:

define dbattrdim dimension text
maintain dbattrdim add 'USE' 'GENDER' 'AGE'

Setting properties on the attribute dimension

Once you have defined an attribute dimension, you then assign the following properties to it:

For each property, define the object and populate it. You can then set the property on the attribute dimension.

For example, suppose you define and populate a relation named domaindimrel, a variable named dbattr_ldscvar, and a relation named rangedimrel. Use the following commands to set the properties for an attribute dimension named dbattrdim:

consider dbattrdim
property 'DOMAINDIMREL' 'domaindimrel'
property 'LDSCVAR' 'dbattr_ldscvar'
property 'RANGEDIMREL' 'rangedimrel'

For more information about an attribute's domain, an attribute's range, and setting properties for attributes, refer to "Metadata That Describes Dimension Attributes".

Setting the DBATTRDIM property on ECMLOCATOR

Once you have defined an attribute dimension, set the DBATTRDIM property on ECMLOCATOR. The following example specifies dbattrdim as the name of the attribute dimension:

consider ECMLOCATOR
property 'DBATTRDIM' 'dbattrdim'

Set the DBFOLDERDIM property to identify the workspace's folders

DBFOLDERDIM is a property that specifies the name of a folder dimension, which you must define and populate. This is a dimension whose dimension values are the names of the folders that exist in the analytic workspace. A folder is a collection of measures that a user considers to be related to one another.

For example, an analytic workspace might contain folders named Financial, Shipments, Market Measurements, Sales, and Human Resources. Folders typically have the same dimensionality, but this is not required. A measure can be in more than one folder. Folders can contain other folders.

To set the DBFOLDERDIM property, follow these steps:

  1. Define and populate the folder dimension.

  2. Set the required properties on the folder dimension.

  3. Set the DBFOLDERDIM property on ECMLOCATOR. The DBFOLDERDIM property will specify the name of the folder dimension that you have defined.

Defining the folder dimension

Use the DEFINE DIMENSION command to define the folder dimension. Then use the MAINTAIN command to specify the names of the folders that exist in the analytic workspace as the dimension values.

Suppose your analytic workspace contains five folders, named FINANCIAL, SHIPMENTS, MARKET_MEASUREMENTS, SALES, and HUMAN_RESOURCES. You can use the following commands to define and populate a dimension named dbfolderdim:

define dbfolderdim dimension text
maintain dbfolderdim add 'FINANCIAL' 'SHIPMENTS' 'MARKET_MEASUREMENTS' -
'SALES' 'HUMAN_RESOURCES'

Setting properties on the folder dimension

Once you have defined a folder dimension, you then assign the following properties to it:

For each property, define the object and populate it. You can then set the property on the folder dimension.

For example, suppose you define and populate a variable named dbfolder_ldscvar and a valueset named measinfoldervs. Use the following commands to set the properties for an folder dimension named dbfolderdim:

consider dbfolderdim
property 'LDSCVAR' 'dbfolder_ldscvar'
property 'MEASINFOLDERVS' 'measinfoldervs'

Setting the DBFOLDERDIM property on ECMLOCATOR

Once you have defined a folder dimension, set the DBFOLDERDIM property on ECMLOCATOR. The following example specifies dbfolderdim as the name of the folder dimension:

consider ECMLOCATOR
property 'DBFOLDERDIM' 'dbfolderdim'

Go to previous page Go to beginning of chapter Go to next page
Oracle
Copyright © 1996-2001, Oracle Corporation.

All Rights Reserved.
Go To Documentation Library
Home
Go To Product List
Book List
Go To Table Of Contents
Contents
Go To Index
Index

Master Index

Feedback