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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
chrislampi
New Member

Publish to Web - Filter Data by User ID?

From what I'm seeing so far, PowerBI is pretty limited when it comes to exposing dashboards/metrics to external users. What I'm trying to determine is whether PowerBI is capable of restricting reports by a particular user's unique User ID. I want to build a single report and have different users see only the data I want them to see based on their permissions. Admins can see everything, users can only see data with their User ID.

 

 

Here's a use case to better articulate the kind of thing I have in mind:

 

I have two users who are generating sales revenue. User A earned $100 in the last 7 days, and User B earned $200 in the last 7 days. I am looking to build a report that shows total revenue earned over the last 7 days, broken out by user. As the admin, I want to be able to see all users and filter as needed, but for privacy reasons I don't want users seeing each other's data.

 

If User A logs in and sees the report I want them to see $100.

If User B logs in and sees the report I want them to see $200.

If I log in as an admin and don't filter by user I want to see $300. If I filter by User A, I want to see $100, and if I filter by User B, I want to see $200.

 

Is this possible?

3 REPLIES 3
Anonymous
Not applicable

Hi @chrislampi,

Publish to web, doesn't support RLS feature.
You can go with Embed feature in Power BI service. This is newly introduced and It also supports RLS.

 

Thanks,

Amit

 

v-lili6-msft
Community Support
Community Support

HI, @chrislampi

You could use USERNAME() function or USERPRINCIPALNAME() function with Row-level security (RLS).

here is some reference:

https://docs.microsoft.com/en-us/power-bi/service-admin-rls

http://radacad.com/dynamic-row-level-security-with-manager-level-access-in-power-bi

http://radacad.com/row-level-security-configuration-in-power-bi-desktop

 Please understand that this link is provided “AS IS” with no warranties or guarantees of content changes, and confers no rights.

 

Best Regards,
Lin

Community Support Team _ Lin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Hi Chrislampi,

You can use USERPRINCIPALNAME() function while creating the roles in Power BI desktop.
Also check this blog post Dynamic Security

 

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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