Introduction
When assigning values to leaf members in a parent-child hierarchy, please note the following scoping method.
Example
Below is an MDX Rule within a Model. In this Rule, although the definition for the Y1 and Y2 members are different, we expect the results to be the same because the following two functions should return the same member set.
DESCENDANTS([Account].[Account].[Income Statement], 1000, LEAVES)
[Account].[Account].Properties(“ChildCount”) = “0”
However, the results we get are different:
The difference comes from the Data Members in the parent-child hierarchy. If we were merely scoping the leaves using the DESCEDANTS MDX function, the Data Member of the parent member would be included in the result set.
Here is the Data Member definition:
A Data Member is a child member associated with a parent member in a parent-child hierarchy. A Data Member contains the data value for its parent member, rather than the aggregated value for the parent’s children.
If your intention is to work with the member leaf only, you can use the Kepion-generated attribute ChildCount. Please refer to the syntax in the MDX Rule example above.