Returns the siblings of the input member, optionally based on selection options.
Syntax
Siblings ( member[, selection [,include_or_exclude]] )
member.Siblings| Parameter | Description |
|---|---|
The member for which siblings are returned. | |
selection | Optional. This option can be one of the following:
If no selection is made, the default is ALL. |
include_or_exclude | Optional. This option can be one of the following:
If neither is specified, the default is to include the input member. |
Notes
If the input member is the top level of the dimension, this function returns a set containing the input member.
In aggregate storage databases, in multiple-hierarchy-enabled dimensions, if the input member is a top-level member of a hierarchy, the output is members across hierarchies that are top-level members of hierarchies.
This function is the same as Children(member.parent).
The member. Siblings syntax returns the same set as Siblings(member), Siblings(member, ALL), or Siblings(member, ALL, INCLUDEMEMBER).
Example
Siblings(Year) returns {Year}.
The following query
SELECT
CrossJoin (
Union (
Siblings ([Old Fashioned]),
{([Root Beer]), ([Cream Soda])}
),
{(Budget), ([Variance])}
)
ON COLUMNS
from Sample.Basicreturns the grid:
| Old Fashioned | Diet Root Beer | Sarsaparilla | Birch Beer | Root Beer | Cream Soda | ||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Budget | Variance | Budget | Variance | Budget | Variance | Budget | Variance | Budget | Variance | Budget | Variance |
| 11640 | -4439 | 14730 | -2705 | 5050 | -414 | 4530 | -438 | 35950 | -7996 | 29360 | -3561 |
The following examples are based on a Years – Quarters – Months Time hierarchy.
Siblings([Feb 2000], LEFT, INCLUDEMEMBER)
Returns {[Jan 2000], [Feb 2000]}.
Siblings([Feb 2000], RIGHT, EXCLUDEMEMBER)
Returns {[Mar 2000]}.
Siblings([Mar 2000], LEFT)
Returns {[Jan 2000], [Feb 2000], [Mar 2000]}.
Siblings([May 2000], RIGHT)
Returns {[May 2000], [Jun 2000]}.
Siblings([Mar 2000])
OR
[Mar 2000].Siblings
Returns {[Jan 2000], [Feb 2000], [Mar 2000]}.