Forum Discussion
Row level security using if-clause
Hi Anonymous ,
yes, I have solved my issue, but I solved it differently, not with a DAX statement in the role setup.
I have created calculated tables, that crossjoin the users that have a * (access to everything) with the respective dimension. The DAX statement you'll need is CROSSJOIN().
For example: User A has access to all companies. I therefore receive one line from my security table like the following:
User: Mark
Dimension: Companies
Restriction: *
I am then crossjoining this line with the company dimension, so I am getting a new table that delivers me the user Mark and all companies that exist in that dimension.
This table you can then use to place the RLS restriction on.
Hope this helps, good luck!
Hi,
Can you please share me the DAX code ?
Regards
Shiva