Skip Headers
Oracle® OLAP Expression Syntax Reference
Release 11.2

Part Number E23381-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Master Index
Master Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
PDF · Mobi · ePub

HIER_CHILD_COUNT

HIER_CHILD_COUNT returns the number of children of either all dimension members in a hierarchy or a particular member. The hierarchy can be either level-based or value-based.

Return Value

NUMBER

Syntax

HIER_CHILD_COUNT ( 
   [member_expression] [WITHIN]
   {DIMENSION dimension_id | HIERARCHY hierarchy_id} ) 

Arguments

member_expression

Identifies a single dimension member within the hierarchy used for the calculation. If this optional argument is specified, then the result does not vary across dimension members.

dimension_id

The dimension over which the values are calculated using the default hierarchy.

hierarchy_id

The hierarchy over which the values are calculated. If dimension_id is used instead, the default hierarchy is used.

Example

This example returns the number of children for each member of the default hierarchy of the Time dimension.

HIER_CHILD_COUNT(DIMENSION "TIME")

Time Children
2006 4
Q1.06 3
Q2.06 3
Q3.06 3
Q4.06 3
JAN-06 0
FEB-06 0
MAR-06 0
APR-06 0
MAY-06 0
JUN-06 0
JUL-06 0
AUG-06 0
SEP-06 0
OCT-06 0
NOV-06 0
DEC-06 0

The next example returns 8 as the number of children for Government within the Market hierarchy of the Customer dimension.

HIER_CHILD_COUNT('GOV' WITHIN HIERARCHY CUSTOMER.MARKET)