Hi Experts ,
I have working on SSAS Cube -2012 .
My Cube is ready and is working fine .
I am stuck while creating a Calculate Measure (In writing MDX)
My Requirement is - When a person log in , based on this Role , Calculate Measure should be Visible or Invisible.
I need to use UserName and IIf function to achieve this , but not getting correct MDX to achieve it .
Requirement : Check the ROLE of a person who has logged in using UserName function
If ROLE =1 Then [Measures].[SALES_AMT]
If ROLE =2 Then [Measures].[SALES_AMT]
ELSE NULL
Below is the Screen shot of the Table and Data to give IDEA of the Dimension and Fact Used in the cube
Emp_ROLE_Fact is Fact Table connected to Employee and Role Dimension in Cube .
Please assist in providing MDX for this Calculated Measure