Technical data
Chapter 11 Using Built-in Functions in Analytic M odels
Example
Suppose you wis
h to calculate the monthly and yearly change in a data cube called SALES. If SALES uses a
dimension c al
led MONTHS, use the following formula to calculate the MONTHLY_CHANGE data cube:
CHANGE(MONTHS
, SALES)
Because the Count argument is omitted, the program assumes it to be 1. Consequently, the program calculates
the change in SALES from the previous month to the month being calculated.
Calculate the YEARLY_CHANGE data cube by using 12 for the third argument:
CHANGE(MONTHS, SALES, 12)
This formula calculates the change in SALES from 12 months ago to the month being calculated.
CHILDCOUNT
Syntax
CHILDCOUNT(Dimension,{#DIRECT/#ALL/#DETAILS,{Parent Member}})
Description
The CHILDCOUN
T function r eturns the number of a Parent member’s children. This function takes the
following one
required argument and two optional arguments:
• Dimension: The dimension to use.
• For the second optional argument, select from these predefined constants:
- #DIRECT.
- #ALL.
- #DETAILS.
See C
hapter 10, “Creating Rules, Formulas, and User Functio ns ,” Understanding the Elements of Rules,
page 120.
• Parent Member: This is an optional argument. If you do not use this optional argument, the function applies
to the member that is currently being evaluated.
Returns
The number of
a parent member’s children.
Example
CHILDCOUNT (
Region, #DIRECT, [Region:All_regions])
See Also
Chapter 9, “Creating H ierarchies,” Pushed Down Data, page 80
CHR
Syntax
CHR(Number)
Copyright © 1988-2007, Oracl e. All rights reserved. 145