Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
ConnieMaldonado
Responsive Resident
Responsive Resident

Row level security - can't get View as other user to work

Hello - I am creating a report in Power BI which uses RLS to limit the view of users when they access the report.

 

I have created a path statement on the Employee Dim table to set up the hierarchy.

Path = PATH('Employee Dim'[Employee_Number],'Employee Dim'[Primary Manager ID])
 

In the Modeling section, I created a User and added a filter on the Employee Dim table as follows:

 

Roles POC.PNG

 

In the service, I added users to the user role and shared the report with them.  

 

For the users I tested, the view was limited, and each person only saw his/her direct reports.

 

However, when I use the "View as Roles" functionality in the desktop from the modeling tab and select "Other user", the view is not limited.  I have admin rights on the workspace - is that why the view is not limited?  I'm trying to test the functionality and see what a specific user sees.

 

When I test from the service using the "Test as Role" from the dataset, it works and the view is limited.  I'd like to know why, though, I can't use the "View as" functionality from the modeling tab in the desktop.

 

Does anyone know?

 

Thanks!

1 ACCEPTED SOLUTION
bcdobbs
Super User
Super User

When you use the view as other user in desktop you have to tick the role as well as give the user name. At that point in the life cycle it doesn't know what roles a user belongs to.

 

In the service you've assigned users (probably via security group) to an RLS role so it knows where they sit.



Ben Dobbs

LinkedIn | Twitter | Blog

Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!

View solution in original post

4 REPLIES 4
bcdobbs
Super User
Super User

When you use the view as other user in desktop you have to tick the role as well as give the user name. At that point in the life cycle it doesn't know what roles a user belongs to.

 

In the service you've assigned users (probably via security group) to an RLS role so it knows where they sit.



Ben Dobbs

LinkedIn | Twitter | Blog

Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!

Wow!  That did it.  Such a simple thing, but I would have never figured it out.  Another question:  Can you add AD groups to the User role?

 

Thanks so much?

Do you mean can you add Azure AD groups to an RLS role? If so yes, and it's 100% what you should be doing.



Ben Dobbs

LinkedIn | Twitter | Blog

Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!

Yes, that's what I meant, and thanks again!

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.