Donate

How To Setup Or Configure Row-Level Security (RLS) In Power BI Using Domain Credentials

Good Evening All!

While I was creating a Power BI report last year,I was tasked to make a report restrict information for a given set of users in our organization. After googling for a few minutes or so, most of the results were pointing me to Row-Level Security. One of the few points mentioned by Microsoft's RLS documentation is that members of a workspace defined in the Power BI service have access to the datasets. In which case are the admins of the workspace. In this report project we have to restrict data through domain account emails. So to start setting up RLS, I need to tweak some settings for both Power BI Desktop and Power BI Service.

I. Power BI Desktop

1. In my sample report, click on Modelling menu then choose Manage Roles.
2. Add New Role called Supervisor Information then click Create.
3. Select Supervisor Information Dataset that contains email or information that will be used to Filter data based on a current role. In this case, I chose the Supervisor Information dataset since it has a field called Email which is basically a domain account.
4. Add DAX expression to get the user principal name which will be stored in email variable.
[Email] = USERPRINCIPALNAME()
How To Setup Or Configure Row-Level Security (RLS) In Power BI Using Domain Credentials
5. I also did set the relationship between Supervisor Information and some of tables like Dependents and Terms in the relationship window to enable filter context of those datasets. (1:*) One supervisor has many Terms or Dependents.

II. Power BI Service

1. Log-in to your account in Power BI Service.
2. Select the dataset of which you want to configure the security by clicking the three ellipse button.
3. Choose Security.
4. Under Supervisor Information, add emails that can view the dataset.
How To Setup Or Configure Row-Level Security (RLS) In Power BI Using Domain Credentials

That's it!

Comments

Donate

Popular Posts From This Blog

WPF CRUD Application Using DataGrid, MVVM Pattern, Entity Framework, And C#.NET

TypeScript Error Or Bug: The term 'tsc' is not recognized as the name of a cmdlet, function, script file, or operable program.

Invalid nested tag div found, expected closing tag input