@SHIFTSIBLING

The @SHIFTSIBLING calculation function for Essbase returns a member's next sibling, at a relative position, as a string.

This function returns the specified member or the nth sibling of the member. This function traverses members that are at the same level and of the same parent. If the specified relative position moves beyond the first or last sibling, Essbase returns an empty string.

This function returns the next sibling as a string. To pass the @SHIFTSIBLING function as a parameter of another function, where the function requires a list of members, you must wrap the @SHIFTSIBLING function call within a @MEMBER function call.

You must also wrap this function within the @MEMBER function if you are calling it inside a member combination specified using the cross-dimensional operator (->). For example, this is correct usage: @MEMBER(@SHIFTSIBLING("FY19"))->"A1".

Syntax

@SHIFTSIBLING (mbrName [,relativePosition])

Parameters

mbrName

Any valid single member name, or a function that returns a single member.

relativePosition

Optional. The integer that defines the position relative to the specified member. Valid values:

  • 0 (Default) Returns the specified member.

  • < 0 (negative integer): Returns the previous sibling.

  • > 0 (positive integer): Returns the next sibling.

Example

All examples are from the Sample.Basic database.

@SHIFTSIBLING("100–20",0)

Returns 100-20 (the specified member).

@SHIFTSIBLING("200",1)

Returns 300 (the next sibling of 200). The @SHIFTSIBLING("200",1) function and the @NEXTSIBLING("200") function return the same results.

Returns 400 (the second-next sibling of 200).

@SHIFTSIBLING("100–20",–1)

Returns 100-10 (the previous sibling of 100-20). The @SHIFTSIBLING("100–20",–1) function and the @PREVSIBLING("100–20") function return the same results.

@SHIFTSIBLING("100–10",9)

Returns an empty string, as 100-10 does not have a ninth sibling.

@CHILDREN(@MEMBER(@SHIFTSIBLING("East")))

Returns all children of East. Because no shift position is specified, the default shift position is 0, which means the current member.