Skip Headers

Oracle9i OLAP Developer's Guide to the OLAP API
Release 2 (9.2)

Part Number A95297-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

Making Queries Using Source Methods, 2 of 8


Selecting Based on Source Value

You can create a new Source from an existing Source by selecting only certain values of the base Source. Typically, you use one of the following methods to select based on the values of the base values:

Source.select(BooleanSource), Source.selectValue(Source)
Source.selectValues(Source)
Source.selectValues(Source[])
BooleanSource.selectValue(boolean)
BooleanSource.selectValues(boolean[])
NumberSource.selectValue(double)
NumberSource.selectValue(int)
NumberSource.selectValue(float)
NumberSource.selectValue(short)
NumberSource.selectValues(double[])
NumberSource.selectValues(float[])
NumberSource.selectValues(int[])
NumberSource.selectValues(short[])
StringSource.selectValue(String)
StringSource.selectValues(String[])

You can also select values using the join method using the syntax shown below.

Source Source::join (Source joined, 
     Source comparison, 
     Source.COMPARISON_RULE_SELECT,
     boolean visible);

Assume that you have a primary Source objects named timesDim that you created from an MdmDimension object named mdmTimesDim and whose values are the calendar values. To select only the those values for 1996, you can issue the code shown in Example 6-1

Example 6-1 Selecting Based on Source Values

Source timesSel = timesDim.selectValue("1996");

Go to previous page Go to beginning of chapter Go to next page
Oracle
Copyright © 2000, 2002 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