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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
WinterGarden
Helper III
Helper III

RLS is working in powerbi desktop but not on powerbi service/workspace

Hi All,

I am facing an issue in which rls is working in powerbi desktop, but not on workspace.
Using a security group to give admin and user access..
Added that security group as workspace viewer.
Still rls is not working.
Do you have any ideas?  

5 REPLIES 5
v-kongfanf-msft
Community Support
Community Support

Hi  @WinterGarden ,

 

It should be noted that there is a difference between using the USERNAME() and USERPRINCIPALNAME() functions in Powerbi Desktop and Powerbi Service. In Desktop, the function returns not the UPN of the login account, but the local UPN. When you add a user in Desktop The result returned after the ID is correct, but if the account ID corresponding to the Service is not added in the Powerbi Service, the correct record cannot be displayed. As the above description shows that the result is empty, it illustrates this problem.

 

Username(),userprincipalname()  return from desktop

vkongfanfmsft_2-1728899010192.png

Username(),userprincipalname()  return from service:

vkongfanfmsft_1-1728898957588.png

 

For more details, you can refer to below document:

Row-level security (RLS) with Power BI - Microsoft Fabric | Microsoft Learn

 

Best Regards,
Adamk Kong

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi,
I've tested that userprinciple name. Created a measure for displaying the userprinciplename(

User = USERPRINCIPALNAME())

and added it into a card in the report.
Published the same report to two different workspace (dev and prod).
It's seems like in the workspace where i am facing this issue when i tested the rls in the security this userprinciple name is showing my name( i've admin access) instead of users mail id used for testing. Where as in the other workspace it is showing the users mail id that is used for testing the user role.
i've admin access to both the workspace. Not sure why this rls is working in dev workspace and not in prod workspace.
do you know what is causing this issue?

Hi @WinterGarden ,

 

Refer to below limination about RLS:

vkongfanfmsft_0-1729220678951.png

 

Best Regards,
Adamk Kong

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

bhanu_gautam
Super User
Super User

@WinterGarden , Can you share more information on this or you can check

 

Role Assignment in Power BI Service: Ensure that the roles are properly assigned to the users or security groups in the Power BI Service. This is a common step that might be missed when transitioning from Power BI Desktop to the Service.

 

Security Group Permissions: Verify that the security group has the correct permissions in the Power BI workspace. The group should have at least the Viewer role to see the content, but for RLS to work, the roles need to be explicitly assigned.




Did I answer your question? Mark my post as a solution! And Kudos are appreciated

Proud to be a Super User!




LinkedIn






Yes, security group has read permission to both report and dataset.
I've created 2 roles
1)Admin
2)Engagement level
problem is that when i test the engagement level role, rls is not working.. ie user can see the admin data
But when i test that user in powerbi desktop data is getting filtered

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

Check out the February 2025 Power BI update to learn about new features.

Feb2025 NL Carousel

Fabric Community Update - February 2025

Find out what's new and trending in the Fabric community.