Forum Discussion
Dynamic RLS role creation based on role name
HI, RafDelgado
You could try to use conditional that logic as this formula to add a RLS
IF(ISERROR(VALUE(USERNAME())), [City] = USERNAME(), [ID] = USERNAME())
Result:
Basic dataRole name = '1677217'Role name = 'A'
Here is pbix file. please try it.
Best Regards,
Lin
- RafDelgado7 years agoHelper II
Hey v-lili6-msft ,
Thanks so much for the reply.
I think I may not have explained it properly, What I would like is something like the below.
But instead of the DAX expression being filtered on the manually typed 16777217, it uses the name of the role instead.
Meaning I could have mutliple roles with different number ids for what I want to filter but not have to go through each table to change the query.
- v-lili6-msft7 years agoCommunity Support
hi, RafDelgado
You could refer to this blog:
http://radacad.com/dynamic-row-level-security-with-manager-level-access-in-power-bi
Best Regards,
Lin
- Anonymous5 years agoNot applicable
I have the same issue. Did you solve it?