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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
23Steve32
Frequent Visitor

Is there a way to tell if RLS is filtering a table using dax

As the subject says, I would like to know if a table has been filtered via RLS - it doesnt look like ISFILTERED picks up on RLS filtering. Is this possible and if so how? 

 

Thanks in advance,

Steve

1 ACCEPTED SOLUTION

Hi @23Steve32 ,

As I mentioned above, we can't create a measure to judge if the data has been filtered, RLS is applied at the dataset level, the measure is created inside the dataset. For objects inside the dataset, it is just the "full" dataset.

Best Regards,

Teige

View solution in original post

4 REPLIES 4
cnonline
New Member

Try creating a simple count measure to RLS table if your using dynamic RLS. But I guess this will work for the usual RLS scenario as well. (RLS is my bridging table) This worked for me!

 

RLS Count = DISTINCTCOUNT(RLS[UNAME])

 

And then I created an another switch measure to change a simple icon image in the report. You can do anything with in switch.

 

RLS Secuity check = SWITCH(
    TRUE(),
    [RLS Count]<=1,"Image link to identify RLS applied", 
    [RLS Count]>1,"Image link to identify RLS not applied", 
    "Default image link"
)

 



 

TeigeGao
Solution Sage
Solution Sage

Hi @23Steve32 ,

Only the owner of dataset can see if the dataset has been set RLS from the Security tab in PowerBI Service, it is a dataset level filter, we can't judge it inside a dataset using a function.

Best Regards,

Teige

Hi @TeigeGao ,

 

Sorry if I wasn't clear, I own the dataset, I have set up some roles in the desktop which will filter different tables depending upon who is accessing the report in the service. 
Basically I have a measure which will look at values from one table if the RLS filters that table other wise it should get the data from another table. I thought the ISFILTERED function would work but it doesnt seem to, so is there a way in a measure to tell if a table has been filtered by RLS?

 

Hope this makes sense,

Steve

Hi @23Steve32 ,

As I mentioned above, we can't create a measure to judge if the data has been filtered, RLS is applied at the dataset level, the measure is created inside the dataset. For objects inside the dataset, it is just the "full" dataset.

Best Regards,

Teige

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

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.