March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
I have a table with the hierarchy A B C D E. And sales for each of these. Now A is the top level management, B is next level under A, etc.
So when an A logs in, he needs to see B, C, D, E with thier sales numbers in the table. And because RLS is applied he will only see the data for basically everyone in his team under him.
If one of the Bs logs in, they see the table as C, D, E and if one of the Cs logs in they will see the table as D, E
For example:
if a regional manager logs in. He needs to see the table as the data for all the area managers under him and then he can drill down the hierarchy to go further. If an area manager logs in instead, he needs to see the default view starting with the district managers.
Using RLS you can only filter the data that one sees, but you cannot set the default view with which the pages and the tables render. Is there any workaround for this?
Solved! Go to Solution.
Hi @johnmenx ,
I created some data:
Table1:
Table2:
Here are the steps you can follow:
1. Modeling – Manage roles – Create – Table filter Dax expression.
PATHCONTAINS('Table1'[Manager ID],
MAXX(
FILTER(
'Table1',[Email]=USERPRINCIPALNAME()),'Table1'[ID]))
2. View as roles.
3. Result:
Refer to :
Dynamic Row Level Security with Organizational Hierarchy Power BI - RADACAD
This is the related document, you can view this content:
Positions in Many-to-Many Relationship - Part 1 - RADACAD
Dynamic Row Level Security with Manager Level Access in Power BI - RADACAD
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi @johnmenx ,
I created some data:
Table1:
Table2:
Here are the steps you can follow:
1. Modeling – Manage roles – Create – Table filter Dax expression.
PATHCONTAINS('Table1'[Manager ID],
MAXX(
FILTER(
'Table1',[Email]=USERPRINCIPALNAME()),'Table1'[ID]))
2. View as roles.
3. Result:
Refer to :
Dynamic Row Level Security with Organizational Hierarchy Power BI - RADACAD
This is the related document, you can view this content:
Positions in Many-to-Many Relationship - Part 1 - RADACAD
Dynamic Row Level Security with Manager Level Access in Power BI - RADACAD
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
133 | |
91 | |
88 | |
64 | |
58 |
User | Count |
---|---|
201 | |
137 | |
107 | |
73 | |
68 |