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
jimen
Regular Visitor

DAX on RLS

Hi all, I wanted to make relationship between the security table and the fact table without having the connection in the modelling part. FacSecAccess is the security table. So I'm planning to do RLS role that can filter which email (in table FacSecAccess) that can access particular permission/department in FacPrmsn table that connected to the Data table without having the connection between the FacSecAccess and FacPrmsn. Any idea on how to do this? 

 

Data and FacPrmsn connection key = DEPT_C

 

FacPrmsn and FacSecAccess connection key = Prmsn/PRMSN

Capture.PNG

1 ACCEPTED SOLUTION
v-rongtiep-msft
Community Support
Community Support

Hi @jimen ,

I have created a simple sample, please refer to my pbix file to see if it helps you.

vpollymsft_0-1648181320016.png

 

Create a measure in table FacPrmsn.

Measure = (LOOKUPVALUE(FacSecAccess[e-mail],FacSecAccess[PRMSN],MAX(FacPrmsn[PRMSN])))

Then create a measure in table FacSecAccess.

Measure 2 = FacPrmsn[Measure]

Then create roles.

vpollymsft_1-1648181456836.png

Then view as the role.

vpollymsft_2-1648181488221.png

If I have misunderstood your meaning, please provide you pbix file without privacy information and desired output.

 

Best Regards

Community Support Team _ Polly

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-rongtiep-msft
Community Support
Community Support

Hi @jimen ,

I have created a simple sample, please refer to my pbix file to see if it helps you.

vpollymsft_0-1648181320016.png

 

Create a measure in table FacPrmsn.

Measure = (LOOKUPVALUE(FacSecAccess[e-mail],FacSecAccess[PRMSN],MAX(FacPrmsn[PRMSN])))

Then create a measure in table FacSecAccess.

Measure 2 = FacPrmsn[Measure]

Then create roles.

vpollymsft_1-1648181456836.png

Then view as the role.

vpollymsft_2-1648181488221.png

If I have misunderstood your meaning, please provide you pbix file without privacy information and desired output.

 

Best Regards

Community Support Team _ Polly

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

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.