Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago

Pre-Filter based upon user viewing

I have a single page report, one of the tables has the manager list (which is related to the rest of the report) 

I need the report to use the viewer details to filter the detail specifically for them so they can only see the information if they've used a filter visual and found their name.


now I know this sits within RLS etc, but I'm struggling with the the actual deployment of it.

I've created a Role 'Manager' on the Manager table: [email] = UserPrincipalName()


^^This suggests its looking to match the email in the table to the email of the user viewing. But the all the data is still showing when I view the report on the service. Do I need to do anything in the security tab? I thought because I had the list (as a table) that would be enough.

I'm sure I'm missing something simple, but I'm stuck!!!

Thanks.

6 Replies

  • aj1973's avatar
    aj1973
    Community Champion

    Hi Anonymous 

    In the Role "Manager" have you added the filters that you want the Manager to see?

     

  • Anonymous's avatar
    Anonymous
    Not applicable

    This is all I've done.

    • aj1973's avatar
      aj1973
      Community Champion

      Yes, but that email filters what in your model?

      Check your relationship. Also test the view before publishing 

       

      • Anonymous's avatar
        Anonymous
        Not applicable

        so this is where I think I'm missing something, feel like I've missed a step but I don't know where.

        when I publish and access the report it just shows me everything.

        Do I need to do anything in this RLS space?




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

    Hi Anonymous ,

     

    Would you please check if the user have access to the workspace with permission greater than the viewer. RLS only work on the user with read permission (viewer). Please refer to https://docs.microsoft.com/en-us/power-bi/collaborate-share/service-new-workspaces#roles-in-the-new-workspaces

     

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

     

    Best Regards,

    Dedmon Dai