IsChildOf Function
Returns TRUE if the dimension member is a child member (self, immediate child member, or descendent) of a given dimension.
- Syntax
-
dimension.reference.IsChildOf(dim-member-reference)
- Examples
-
Customer.IsChildOf(Retail) Source.Dept.IsChildOf(Sales) Source.Dept.IsChildOf( "Sales" & "and Marketing" ) Product.IsChildOf(Source.Chnnl.Reference) Product.IsChildOf(trim(Source.Chnnl.Reference))Note: The dim-member-reference does not have to be the immediate child member of the dimension.reference. For example, suppose you have the following hierarchy:Products Wholesale ProductLineA Product1 Product2 ProductLineB Product3 Product4 Retail ProductLineC Product5 Product6 ProductLineD Product5 Product6In this case, the formula
Products.IsChildOf(ProductLineB)tests TRUE for Product3 and Product4. - Further explanation
-
If the account's intersection dimension member reference matches the string passed, TRUE is returned. For example, if the intersection has member Region.Raleigh and the formula has "Region.IsChildOf(Raleigh)", then TRUE is returned. IsChildOf() must evaluate in the context of a dimension member. To accomplish that, use compound references as shown in the examples to select a dimension member on an account's intersection. If an integer is passed, then it is taken as-is without converting it to a number. This special case allows for syntax such as Period.2021 instead of requiring Period."2021".
Note: When used in the assignment rule for a rule-based driver, the member reference is assumed to refer to the destination account unless Source is specified.
Filter by the Value of One or More Dimensions
You can select all rows in a transaction table that have one or more columns whose value matches (or doesn't match) values in dimension tables.
In the following picture, the selection criterion IsChildOf(Product, '[DIM_PRODUCT].[Credit Products]') AND IsChildOf(Channel, '[DIM_CHANNEL].[ATM]') selects six rows in the transaction table:
Notice that the IsChildOf property allows you to select from any point in a dimension hierarchy tree, and all children of that hierarchy are selected.
