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

Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now

Reply
Daniel29195
Super User
Super User

RLS not working

Hello,
im testing the dynamic RLS, 
i have the following table. 

Daniel29195_0-1685306218921.png


RLS formula 1 ; 

VAR _key =
CALCULATEtable(
values('Table'[empid]),

'Table'[adress] = username())


RETURN
PATHCONTAINS('Table'[emppath], _key )

 

testing RLS on test1 :  test1 , should see all other users. ( the above code doesnt worrk)

Daniel29195_2-1685306287283.png

Daniel29195_3-1685306333917.png




 

RLS formula 2 : 
VAR _key =
CALCULATEtable(
values('Table'[empid]),
filter(
'Table',
'Table'[adress] = username())
)

RETURN
PATHCONTAINS('Table'[emppath], _key )

 

with this code, 
the RLS works. 

Daniel29195_4-1685306415996.png

 

so im confused about why the first code didnt work .

 

 

any help explaining the reason why the first code didnt work correctly, but the second did would be appreciated,

 

 

 



1 REPLY 1
Mahesh0016
Super User
Super User

 

@Daniel29195 

Go to manage role 
select table column 
for E.g [Adress] = USERNAME() click OK.
Than
Go to View As 

Check 

Mahesh0016_1-1685361753491.png

Mahesh0016_2-1685361781554.png

 


@Daniel29195 I hope this helps you!THANK YOU!!

Helpful resources

Announcements
Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.