Forum Discussion
Need to create RLS for Existing Active directories groups
Hello first i will thank u for ur reply dilkushpatel
In my case I want dynamic groups i.e i dont want to maintain a data sources of the users as like another table and create a relationship with main data source inorder to works as a filter.. becuase if any new user comes/ old user has to be remove we need to be do it manually...
So We already had dymaic AD groups with lots of users i just wanted use them in my Report for RLS .. is there way to do that..
Please suggest regarding this..
You will be able to add your groups to RLS settings but how will power BI know what data to show for this user?
Usually how it works is we have one user table which will get filtered by logged in users id and then rest of the tables will get filtered due to relationship and a result you see needed data.
You can always import data from your active directory into SQL and ultimately into Power BI (unless there is a direct way which I do not know).
- Raam289 years agoFrequent Visitor
dilkushpatel thank you .. Now i am geeting some ideas
Can you please give the steps to import the users and groups of AD to power BI and how we can make relationship with our charts?
- osinquinvdm9 years agoAdvocate II
importing is OK for the short term but I'd be interested in ways to make that link dynamic.
Today I have a table in Power BI with all my users and the groups they belong to.
Using the username() function I can get their username, then relate it to their group(s) and filter the data accordingly.
but maintaining that user+group table is tedious and error prone so it would make more sense to rely on AD.
and it only makes sense if we can do it dynamically, with a function that would return the list of groups/roles in AD the current user is associated with.
- osinquinvdm9 years agoAdvocate II
I actually found how to achieve this and documented it in https://community.powerbi.com/t5/Desktop/How-to-leverage-Active-Directory-to-filter-the-data-in-Power-BI/td-p/140479