Oracle9i OLAP User's Guide Release 2 (9.2) Part Number A95295-01 |
|
OLAP_TABLE Function, 2 of 6
One way to access multidimensional data is by using the OLAP_TABLE
function. The OLAP_TABLE
function is a predefined table function that returns a table of objects that map to analytic workspace data.
Before you can access multidimensional data using the OLAP_TABLE
function, you must take the following steps:
OLAP_TABLE
function and define any additional objects as described in "Preparing an Analytic Workspace for Access by OLAP_TABLE".Once you have created type definitions and defined the necessary analytic workspace objects, you can make selections of that data using a SELECT
statement with the OLAP_TABLE
function which works like a regular table function. By using it within a SELECT
statement you can select data from the analytic workspace or create a view of analytic workspace data.
The simplified syntax for using the OLAP_TABLE
function in a SQL SELECT
statement is shown below:
SELECT * FROM TABLE(OLAP_TABLE (aw-attach, table-name, olap-command, limit-map)) AS table-name;
Additionally, by coding the OLAP_TABLE
function directly in a SELECT
statement of a CREATE VIEW
command, you can create a relational view of analytic workspace data without using the CWM2_OLAP_AW_ACCESS
PL/SQL package.
For the complete syntax of the OLAP_TABLE
function, see "Syntax: OLAP_TABLE Function". For an example of its use, see "Example: Using the OLAP_TABLE Function".
|
Copyright © 2001, 2002 Oracle Corporation. All Rights Reserved. |
|