Forum Discussion

carlol's avatar
carlol
Resolver I
4 years ago

RLS: Default slicer Selection

 

RLS , Restricts the data shown 

 

  1. I have a silcer , allows the user to select a country 
  2. I many different roles , some roles are restricted to one country , others can see all 
  3. I can choose select all as default , will work perfect for some but a person with access to all countries will be greeted with an unsightly set of charts, if I choose a random country as default this will show nothing for Roles who do not have access

 

To accomodate for every role ideally I would like to set a default ,

I would define the default as the first country in the restricted dataset as defined by the role

i.e. Role A is restrited to Germany , default country is germany

i.e Role B is restricted to all countries, default Country is first country in the list

 

I am not sure if this will work , RLS will have to executed (the data restricted) then the Calculated Column execute ; I dont think we have control over the execution 

 

Maybe an option , 

 

  1. Create a Custom Col called Default 
  2. Function to getfirst Country in the list (assumption RLS is executed, before the function)
  3. Have Default , checked within the slicer  

3 Replies

  • v-janeyg-msft's avatar
    v-janeyg-msft
    Community Support

    Hi, carlol 

     

    Sorry, there is really no way to select the default value you want based on the slicer if you use rls.

    AFAIK, When you don't select a value on the slider by default, other visuals will be displayed according to all the data (if there is RLS, it will be all the data he can see).  There will be no mismatch without setting a fixed value, The easiest way is to leave it empty then let the user choose themselves.

     

    Did I answer your question ? Please mark my reply as solution. Thank you very much.
    If not, please feel free to ask me.


    Best Regards,
    Community Support Team _ Janey

  • Not what I want , a user with access to all , will see an unreadable dashboard and I want to avoid having two dashboards , onw with / without rls 

     

    I will implement my solution 

     

    • v-janeyg-msft's avatar
      v-janeyg-msft
      Community Support

      Hello carlol 

       

      I don’t know what you mean by two dashboards? But once RLS is applied in a report, all users(need to view)must be configured, regardless of his permissions, otherwise he will not be able to see all the content.

      And If the user has edit permission, RLS won't work.

       

      Best Regards,
      Community Support Team _ Janey