What is Object-Level Security (OLS) in Power BI? | RLS Vs OLS in Power BI | Power BI

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello everyone welcome to bi consulting pro this is another session for the security in power bi that means how you can protect your data into power bi we are going to discuss about rls versus ols rls is the role level security which we have already discussed couple of times on our channel but in this session majorly we are going to discuss about the object level security so enough all the talking let's get started so guys we already know the rls in power bi i have made already a couple of videos on that if you are not aware about it please check the link in the description section and you can go through that or also you will find links somewhere above so please don't forget to check them out basically row level security with power bi can be used to restrict data access for given users filters restrict data access at row level and you can define filters within rows so that's how you can restrict the accesses based on the roles that you define in your power ba model now if we talked about the ols that is object level security so what it does do basically it enables model authors to secure specific tables or columns from the report viewers from a viewer's standpoint the table or column simply does not exist with object level security you can not only restrict access to the data but also sensitive object name this prevent users from discovering sensitive data such as employee or inside of financial records now we are gonna see how we can implement ols but before going into that you should have installed the tableau editor onto your desktop or the machine where you are working plus the latest power bi desktop application and if you haven't downloaded then i'll request you to go and download now question comes what kind of model i'm using over here so over here you can see i'm using adventure works dw2019 data model over here effect internet sales is my fact table over here where my sales data is there and then the other tables are over here the dimensional tables so now i'm gonna use this model to create the ols so what i'm gonna do in this session i'm going to restrict the sales data because sales data is your financial data and like quantity data that is your non-financial data also we are going to create an rls role as well just to show that how it's different from the rls and then we will see how it actually works so let's get started over here very first what i'm gonna do i'm gonna create two cards [Music] now let's plot one more graph as well so for that let me take this clustered bar graph over here so now you can see that i have a chart where i am seeing my sales by region then i have two cards in the first card i have known financial data which is my order quantity and then i have another chart where i'm gonna show the financial data which is my sales amount so what i expect from this model or this report that if somebody who has the financial access can see the financial as well as non-financial information but if somebody has no access on the financial data he can only see this order quantity data our next step would be first to create the roles so let's create the roles first and now i'll go into my modeling tab and there's a managed role so let me expand this step here so this is the managed role you can come over here and here we are going to create a role so this road is on the dim sales territory table so here we have our data for the region and the countries so here i'm gonna say my sales territory region should be equals to let's say australia so this is what you need to do this is your the very first role but now we have to create another role as well which would be my non-financial role financial data we don't need to create the roles we can restrict the data using ols that is object level security so let's rename this role to say australia because it's for the australia region only and now i'm gonna create a known financial role as well non-financial role and in the non-financial role i'm not gonna mention anything now we have created two roles and if you would like to verify your role then you can check that too you would come over here and you can check it while you are creating the row but i have already did it so no need to do that just click save so you have created two rows over here now now the question comes when we have to configure ols into tabular model as i mentioned earlier you should have installed the latest version of the tabular module before working on the ols that is object level security now i'll go in my external tool and here you can see that i have this tabular model what i'm gonna do i'm gonna open my tablet editor and here you can see my model is over here since we have already created some roles in the power bi file so we can check and you will see there are two roles one is australia another is the non-financial row if we are gonna apply the same either in the measure then we have to also consider the column name or we are going to apply directly the column into a card then also we have to apply that column name security so don't need to worry about that now what we need to do we need to open our tabular model and now i have to see my table over here on which i have to apply my object level security now since my both the fields are coming from the fact internet sales table so we have to apply there the ols and for that what we can do will go into that particular table which is my fact internet sales table over here you can see this is the table and there are the two columns one is the sales amount another is the order quantity order quantity is over here and then i have my sales amount over here so these are my two columns where i have to apply my object level security okay so this is the table where i have my two columns now what you need to do you have to go back that is my known financial role where i didn't do anything so over here i have to double click on this one and then you will see there are the different options available over here on my right hand side panel so let me expand this a bit and you are here you will see the table permissions so since my table is the fact internet sales table where i have to apply this object level security what i can do i'll go in my table that is my effect internet sales table and here you can double click on this one and then you will find this fact internet sales table over here you would expand this under the ols column expression and here what you can do you will come down and then you will find your columns on which you are going to create your object level security and by default it would say it's default but since we have to make sure that no one can access this financial data so what i can do i'll go into my sales amount one and here i can make it to none so you will see none and read read means they can view the data they can read it and default means whatever the default setting is there and none means nobody can view this one so let me make it none and now another one is the order quantity so i'm gonna make it to read so that's all you need to do over here not only this whenever you have a number of columns here you can make them either read or none or default if you want to let the users to read the data that should be read otherwise you can keep it default so once we made these changes you would try to save this and then if you are getting this kind of error message read it carefully it's saying that a column permission object referring to a column order quantity cannot be less restrictive than its corresponding table permission object referring to a fact internet sales that means we have to check the fact internet sales tables permission and if i'll come over here on my effect internet sales table under my security so you will see over here under object security if i'll expand this this is saying none it should not be none it should be read so either you can make it default or read so up to you so now if you read then try to save it and you will see your object level security has been saved now we have to test it out so for that i have to publish this report on my power bi services in order to check it i want to check only on my power bi service not over here so let me publish this so now you can select your workspace over here and publish this one now it's been published we can click on the link and here i am on my power bi services and this is my report so what i need to do i have to go my demo workspace and then i have to click on these three dots on my data set rls versus ols and go to security and here you can see i have different roles now the very first was i need to check my australia role which is my rls role so what i can do i can say test as a role and you can see that it's only showing data corresponding to the australia so we have filter it out based on the region equals to australia so this is the only data which you will see now i have to check another one so what i can do i'll uncheck this i'll check this and apply so now you can see that in both the cases wherever it was using sales amount column that is my financial data it's not displaying the same over here because it's saying the visual has unrecognized field anytime you want to hide any financial or not even financial any kind of field from your report for the power bi report consumer or the viewers then you can apply this object level security and i believe that this is gonna be very much helpful for you guys i know in many industries or the organizations people are looking for this kind of security implementation which was not available earlier in power bi it was just the rls and you know that power bi is growing exponentially day to day they are implementing a lot of new features the data protection is very very important for every organization without protection we cannot do anything so guys let me know what do you think about this and share your feedback with us and don't forget to subscribe our channel and hit the bell icon for more updates [Music]
Info
Channel: BI Consulting Pro
Views: 26,542
Rating: undefined out of 5
Keywords: Power BI, object level security in power bi, OLS in Power BI, Row level security in Power BI, RLS Vs OLS in Power BI, RLS Vs OLS, BI Consulting Pro, power bi tutorial advanced, power bi tutorial from beginner to pro, power bi tutorial for beginners, Creating Roles in Power BI, publishing power bi reports, publishing power bi reports to web, Testing roles in Power BI, power bi interview questions, Ajay Kumar, OLS implementation in Power BI, rls implementation in power bi, roles
Id: 0Tj_TqbzFMM
Channel Id: undefined
Length: 12min 43sec (763 seconds)
Published: Sat Mar 20 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.