Search code examples
ssasparent-childmdxhierarchyolap

MDX Allow member set only siblings in Roles-Dimension Data


Is it possbile to restrict a Role in Dimension Data by allowing him to see only siblings in the parent-child Hierarchy? Example Hierarchy:

EMEA              100

  UK               50
     London        30
     Southampton   20

  France           50
      Paris        10
      Lyon         40

To see only:

  EMEA             100
     UK             50
     France         50

Role


Solution

  • I've received the expected result with the following MDX statement

     NONEMPTY(
        descendants(
           [Dim Branch Hierarchies].[Branch Hierarchy]
           ,,leaves
        )
      , (
         [Measures].[GrantedHi]
        ,StrtoMember( 
            "([Dim Users].[Account Name].[Account Name].["+ Username()+ "])" 
         )
        ) 
    )