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
creedrulz
Frequent Visitor

RLS doesn't work for direct reports when user principal name is different to email address

Hi ,

 

I have created a RLS role called "direct report" which filters the currently logged-in user data as well as his direct reports.


var current_logged_in =

LOOKUPVALUE(dim_IvmsOperator[IVMSOperator_SK],dim_IvmsOperator[OperatorEmailAddress],USERPRINCIPALNAME())

return
PATHCONTAINS(dim_IvmsOperator[Emp_Path],current_logged_in)

 

The issues arise when the user's principal name is different from the email address. 

 

our company standard email is firstname.lastname@xyx.com  which is aligned with the user principal name for most cases but there are exceptions that have different user principal names such as Paul.J.Rodd@xyz.com instead Paul.Rodd@xyz.com. Apparently, there were quite a few. Does anyone know a workaround for this issue? Any help is greatly appreciated .

 

 

Thanks,

Dee

 

 

 

 

 

3 REPLIES 3
creedrulz
Frequent Visitor

@amitchandak 

 

the data is already there and pulled from a dimension table in sql called dim_oprator which has what you mentioned (i.e email , operator id , leader id  user names etc)

does anyone have come across any instance as such? still trying to figure out a workaround.

amitchandak
Super User
Super User

@creedrulz , Better to have a table which takes care of this

example

email1, email , dept

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.