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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Jon_Berry
New Member

RLS based on user, but only in certain areas of the report

Hello, this is my first post so forgive me if its in the wrong place or doesnt have the right info.

 

We are using PBI embedded through a webapp and would like the ability to filter certain parts of a report based on users logged in USERNAME()

We are using a Service Principle but are able to send through the user idintity to PBI. So when I look at the USERNAME() in PBI desktop I see the correct user identy information.

 

We are using a single data set for multiple reports. Which is all Direct Query from an on prem Gateway.

 

I can create a Measure as below,

ActiveUserNameFilter =
CALCULATE (
IF (
MIN ( ss_dim_Users[emailAddress] )
= USERNAME (),
1,
0
)
)
 
Which works on a single table etc, but not visulisations, also as its a Measure, not pages or reports level filters.

The ideal is for a two state filter (1,0) that can be used at Report and Page level and also at an individual visualisation level as some of the report requirements are that users only see their detailed data, but have some headline numbers for the entire organisation.
 
Any help would be greatly appreciated.
 
 
1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Jon_Berry,

AFAIK, RLS is applied on data model tables. If you do not want to the RLS effect applies to specific contents.
You can break the relationship between these tables to make the target table as 'standalone' tables.

After these steps, these filter effects will only apply to the tables which link with 'username' mapping tables.

Regards,

Xiaoxin Sheng

View solution in original post

1 REPLY 1
Anonymous
Not applicable

Hi @Jon_Berry,

AFAIK, RLS is applied on data model tables. If you do not want to the RLS effect applies to specific contents.
You can break the relationship between these tables to make the target table as 'standalone' tables.

After these steps, these filter effects will only apply to the tables which link with 'username' mapping tables.

Regards,

Xiaoxin Sheng

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.