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

The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!

Reply
andrew_hardwick
Helper III
Helper III

DAX does not contain function for RLS Filter

I am trying to create a filter for Row Level Security to check if the team contains the value "HR". We have multiple HR teams, so to ensure I capture all HR teams, I wanted to write a DAX script to say contains.

 

At present I can do this on a single team using the DAX below-

 

[Team]<>"ME HR Shared Services"

 

However ideally I would like it to be something like-

 

[Team] Not(Contain("HR")

 

Any ideas?

 

Thanks

 

Andy

1 ACCEPTED SOLUTION
Peter_R
Resolver II
Resolver II

try FIND("HR", [Team], 1, -1) = -1   (to exclude any team name that contains 'HR')
or FIND("HR", [Team], 1, -1) > -1 (to only allow where the team contains "HR")

View solution in original post

2 REPLIES 2
Peter_R
Resolver II
Resolver II

try FIND("HR", [Team], 1, -1) = -1   (to exclude any team name that contains 'HR')
or FIND("HR", [Team], 1, -1) > -1 (to only allow where the team contains "HR")

Fantastic, that works exactly! Thank you.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! It's time to submit your entry.

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 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.