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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
_chris_
Helper II
Helper II

Problems with RLS behaviour

Hi,

 

I have three tables:

 

1. Costcenters

2. Staff

3. RightsStaffCostcenters

 

I have two relations:

RightsStaffCostcenters has an m:n relation to Costcenters (one staff/manager can have the rights the see the employee data of multiple costcenters)

Costcenters has 1:n relation to Staff (1 employee is assigned to 1 costcenter but one costcenter can have multiple employees)

 

Let´s say, one manager has the rights to see the staff data of two costcenters.

 

When create a manual filter in the filter pane for the RightsStaffCostcenters table to the StaffId of the manger, my staff visual show all employees of the these two costcenters.

 

Now, I do not want to filter manually but using RLS. Now, when the manager logs in he sees only the employee data of one costcenter.

 

[StaffId]=LOOKUPVALUE(Staff[StaffId], Staff[EMail], CONCATENATE(LEFT(USERPRINCIPALNAME(), FIND("@", USERPRINCIPALNAME())), "xxx.de")) 

 

Can someone help me with this?

 

Thanks and merry christmas to everyone

 

BR Christian

3 REPLIES 3
_chris_
Helper II
Helper II

@negi007 Thanks a lot for your offer to help! That is what I was initially hoping for 🙂 However, as I want to learn things by myself, let me please first go through the article sent by and try it by myself as this seems to cover my issues @amitchandak .

 

I will come back to you.

 

Thx Christian

negi007
Community Champion
Community Champion

@_chris_ will it be possible for you to share sample data for these tables. will then assist you accordingly. 




Did I answer your question? Mark my post as a solution!
Appreciate your Kudos



Proud to be a Super User!


Follow me on linkedin

amitchandak
Super User
Super User

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

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.