Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
powerbiasker
Helper IV
Helper IV

RLS issue: how to enable some users to see all rows?

Hello,

 

I have created/used row-level security (RLS) with Power BI Desktop to restrict data access for given users at the Power BI Service website. But, after that, how to enable some users, like super users, to see all rows? 

 

For example, I define Role_1 for the Region_A info, Role_2 for the Region_B info. This works fine on the Power BI Service website: the Role_1 users only see Region_A info; the Role_2 users only see Region_B info.

But, if I want a super user X to view all regions info, how should I do?

 

If I do nothing about X's security, X told me that he could not see any info and got a pop-up alert showing that: "This visual contains restricted data."

 

How should I do?

 

2 ACCEPTED SOLUTIONS
TomMartens
Super User
Super User

Hey @powerbiasker ,

 

simply create a role e.g. SuperUser.

To be consistent I use the table that contains the region column and then I provide simply this:

image.png

The DAX statement is a simple TRUE.

 

Hopefully, this provides what you are looking for.

 

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

View solution in original post

v-yingjl
Community Support
Community Support

Hi @powerbiasker ,

It can be divided into two situations:

  1. You can add this super user to the workspace as contributor / member / admin in new workspace or admin in classic workspace who is not restricted by RLS so that they can see all data in this report directly.
  2. If the super user email is in the dataset, you can create a column to mark whether he is a super user( like yes is 1 / no is 0), it seems like dynamic RLS with a manager level, role formula is like this:

 

IF (
    MAXX ( FILTER ( 'Email', 'Email'[Email] = USERNAME () ), 'Email'[Is SuperUser] ) = 0,
    'Email'[Email] = USERNAME (),
    TRUE
)​

Test result:

A is not a super userA is not a super userSuper user can see all dataSuper user can see all data

 

You can refer this article and I have created a sample file

 

Best Regards,
Yingjie Li

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

 

View solution in original post

3 REPLIES 3
Uatilla
New Member

Amazing solution!
Thanks for sharing!!

v-yingjl
Community Support
Community Support

Hi @powerbiasker ,

It can be divided into two situations:

  1. You can add this super user to the workspace as contributor / member / admin in new workspace or admin in classic workspace who is not restricted by RLS so that they can see all data in this report directly.
  2. If the super user email is in the dataset, you can create a column to mark whether he is a super user( like yes is 1 / no is 0), it seems like dynamic RLS with a manager level, role formula is like this:

 

IF (
    MAXX ( FILTER ( 'Email', 'Email'[Email] = USERNAME () ), 'Email'[Is SuperUser] ) = 0,
    'Email'[Email] = USERNAME (),
    TRUE
)​

Test result:

A is not a super userA is not a super userSuper user can see all dataSuper user can see all data

 

You can refer this article and I have created a sample file

 

Best Regards,
Yingjie Li

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

 

TomMartens
Super User
Super User

Hey @powerbiasker ,

 

simply create a role e.g. SuperUser.

To be consistent I use the table that contains the region column and then I provide simply this:

image.png

The DAX statement is a simple TRUE.

 

Hopefully, this provides what you are looking for.

 

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.