Oracle® OLAP Reference 10g Release 2 (10.2) Part Number B14350-01 |
|
|
View PDF |
The following statements create the SALES_AMOUNT
and SALES_QUANTITY
measures for the SALES_CUBE
cube.
execute cwm2_olap_measure.create_measure ('JSMITH', 'SALES_CUBE', 'SALES_AMOUNT', 'Sales Amount', '$ Sales', 'Dollar Sales'); execute cwm2_olap_measure.create_measure ('JSMITH', 'SALES_CUBE', 'SALES_QUANTITY', 'Sales Quantity', 'Sales Quantity', 'Quantity of Items Sold');
Table 18-1 CWM2_OLAP_MEASURE Subprograms
Subprogram | Description |
---|---|
|
Creates a measure. |
|
Drops a measure. |
|
Locks a measure's metadata for update. |
|
Sets the description for a measure. |
|
Sets the display name for a measure. |
|
Sets the name of a measure. |
SET_SHORT_DESCRIPTION Procedure |
Sets the short description for a measure. |
This procedure creates a new measure in the OLAP Catalog.
A measure can only be created in the context of a cube. The cube must already exist before you create the measure.
Descriptions and display properties must also be established as part of measure creation. Once the measure has been created, you can override these properties by calling other procedures in this package.
Syntax
CREATE_MEASURE ( cube_owner IN VARCHAR2, cube_name IN VARCHAR2, measure_name IN VARCHAR2, display_name IN VARCHAR2, short_description IN VARCHAR2, description IN VARCHAR2);
Parameters
Table 18-2 CREATE_MEASURE Procedure Parameters
Parameter | Description |
---|---|
|
Owner of the cube. |
|
Name of the cube. |
|
Name of the measure. |
|
Display name for the measure. |
|
Short description of the measure. |
|
Description of the measure. |
This procedure drops a measure from a cube.
Syntax
DROP_MEASURE ( cube_owner IN VARCHAR2, cube_name IN VARCHAR2, measure_name IN VARCHAR2);
Parameters
Table 18-3 DROP_MEASURE Procedure Parameters
Parameter | Description |
---|---|
|
Owner of the cube. |
|
Name of the cube. |
|
Name of the measure to be dropped from the cube. |
This procedure locks the measure's metadata for update by acquiring a database lock on the row that identifies the measure in the CWM2
model table.
Syntax
LOCK_MEASURE ( cube_owner IN VARCHAR2, cube_name IN VARCHAR2. measure_name IN VARCHAR2, wait_for_lock IN BOOLEAN DEFAULT FALSE);
Parameters
Table 18-4 LOCK_MEASURE Procedure Parameters
Parameter | Description |
---|---|
|
Owner of the cube. |
|
Name of the cube. |
|
Name of the measure to be locked. |
|
(Optional) Whether or not to wait for the measure to be available when it is already locked by another user. If you do not specify a value for this parameter, the procedure does not wait to acquire the lock. |
This procedure sets the description for a measure.
Syntax
SET_DESCRIPTION ( cube_owner IN VARCHAR2, cube_name IN VARCHAR2, measure_name IN VARCHAR2, description IN VARCHAR2);
Parameters
Table 18-5 SET_DESCRIPTION Procedure Parameters
Parameter | Description |
---|---|
|
Owner of the cube. |
|
Name of the cube. |
|
Name of the measure. |
|
Description of the measure. |
This procedure sets the display name for a measure.
Syntax
SET_DISPLAY_NAME ( cube_owner IN VARCHAR2, cube_name IN VARCHAR2, measure_name IN VARCHAR2, display_name IN VARCHAR2);
Parameters
Table 18-6 SET_DISPLAY_NAME Procedure Parameters
Parameter | Description |
---|---|
|
Owner of the cube. |
|
Name of the cube. |
|
Name of the measure. |
|
Display name for the measure. |
This procedure sets the name for a measure.
Syntax
SET_MEASURE_NAME ( cube_owner IN VARCHAR2, cube_name IN VARCHAR2, measure_name IN VARCHAR2, set_cube_name IN VARCHAR2);
Parameters
Table 18-7 SET_MEASURE_NAME Procedure Parameters
Parameter | Description |
---|---|
|
Owner of the cube. |
|
Name of the cube. |
|
Original name of the measure. |
|
New name for the measure. |
This procedure sets the short description for a measure.
Syntax
SET_SHORT_DESCRIPTION ( cube_owner IN VARCHAR2, cube_name IN VARCHAR2, measure_name IN VARCHAR2, short_description IN VARCHAR2);
Parameters