cancel
Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Reply
rimah
Frequent Visitor

DirectQuery RLS

Could someone please tell me How I can configure RLS on a dataset using DirectQuery and import, in power BI?

I have a table that imported and I added a role on it "UserprincipalName()" but when I tried "View as Role" only the table that I added a role on it is filtred but the others are not. 

 

I can not see this when I add a relation between the imported table and the DQuery Table

rimah_0-1658359261344.png

 

6 REPLIES 6
amitchandak
Super User
Super User

@rimah , Usually this is what we do, we take a global dimension and filter that using RLS.

The global dimension is one which joins with all fact example like region, item, customer etc

Sorry, but how can we add Rls on a DirectQuery table in power BI is it even possible.

I am adding Rls on an imported table that is a global dimension but it's only filtering itself.

Hi @rimah ,

 

You need turn off the apply security filter in both directions when you use RLS.

vchenwuzmsft_2-1658815626435.png

 

vchenwuzmsft_0-1658815495267.png

Result:

vchenwuzmsft_1-1658815530189.png

 

If you need more help, please share some example data.

 

Pbix in the end you can refer.

Best Regards

Community Support Team _ chenwu zhu

 

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

 

 

 

Thank you for your answer, unfortunately, I can not see the data, I don't have access,

rimah_1-1658858475575.png

 

but my question is about the table "TABEL" is DirectQuery so how can you see it here 

rimah_0-1658858344084.png

in my report when I can not see all the tables that are in DirectQuery mode in the "Role" second when I add a role like you did my data is not filtred I see all data (I am using Dynamic RLS  USERPINCIPALNAME).

Hi @rimah ,

 

Can you share your pbix file without sensitive data or some screenshot of your filter dax in rls role.

 

Best Regards

Community Support Team _ chenwu zhu

 

rimah_0-1658949250982.png

As you can see I only can see the imported tables and the filter that I added does not work on the other table(DirectQuey)

Helpful resources

Announcements
PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Community News

Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

Dashboard in a day with date

Exclusive opportunity for Women!

Join us for a free, hands-on Microsoft workshop led by women trainers for women where you will learn how to build a Dashboard in a Day!

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors