Forum Discussion

jdusek92's avatar
jdusek92
Advocate III
7 years ago

Row level security and relationship

Hello,

I have this data model:

relationship model:

 

I want to use Row Level security via UserPrincipalName() expression.

I have set up a role for table Employees:

[UserPrincipalName] = userprincipalname()

 

When I view report as a specific user only two tables are filtered correctly:

 

 

But when I tick "Apply security filter in both directions", it filters all the tables:

 

 

My question:

  1. Why do I have to tick "Apply security filter in both directions" for the second relationship, but and not for the first
  2. What exactly does this option do?

 

sample data here:

https://drive.google.com/file/d/1chwlT_cP3QPvMCC2IH2hxq-TkJhulTLb/view?usp=sharing

 

As you can see I want to use Power BI and Row Level Security for HR reporting with sensitive information. I want to be sure that employees cannot reach irrelevant data.

 

Warm regards,

Jakub

 

8 Replies