cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
JoshAsh
Frequent Visitor

Test as Role - how to choose which report is displayed, and how is the default chosen?

When I select 'Test as Role' on a Power BI dataset in order to test row level security a report is chosen seemingly randomly in that workspace to use as the test

 

- How does the service choose which report is displayed when 'test as role' is used?

- How can we choose which report is displayed when 'test as role' is used?


There are multiple reports we would like to test.

 

Thanks,
Josh

1 ACCEPTED SOLUTION
Burningsuit
Super User
Super User

HI @JoshAsh 

"Test as Role" will only show the first report connected to a Dataset. If you look at the lineage view of the Dataset this will be the top report on the list of reports connected to the Dataset. Currently, there is no way to choose any other report to test with 'test as role' . If you have multiple reports to test you'll have to login as the user and view the reports through their login to check RLS is applied correctly.

Hope this helps

Stuart

View solution in original post

4 REPLIES 4
mister_bark
Frequent Visitor

It wants to default to the base connected report but you can get it to connect to a different report by making that the most recent report viewed, following the steps below:

1. open the report that on which you want to test RLS

2. Refresh the page

3. Click on the ellipsis (…) on the top bar (near edit) and click 'See related content'

4. Click on the ellipsis (…) next to the dataset and click 'Security' which will take you into the dataset security menu

5. Next to the role you want to test click the ellipsis (…) again and select 'Test as role' 

6. This will launch the report with RLS testing enabled

ChristianVolder
New Member

I might have found a work around. I do not know enough about free, pro and premium licences. This is done with Premium workspace for the dataset and MyWorkspace for reports.

1. Publish report from desktop to a workspace #1.

2. Delete the report but not the dataset.

3. Publish the report from desktop to another workspace #2 but still connected to the dataset from workspace #1.

4. Change the report, rename it or find an other report and connect it to dataset from workspace #1. Publish to workspace #2.

5. Now you should have two reports in workspace #2 and only a dataset in workspace #1

6. When testing roles on the dataset on workspace #1 no report will automatically open. Instead go to workspace #2 and pick the report you want.

Burningsuit
Super User
Super User

HI @JoshAsh 

"Test as Role" will only show the first report connected to a Dataset. If you look at the lineage view of the Dataset this will be the top report on the list of reports connected to the Dataset. Currently, there is no way to choose any other report to test with 'test as role' . If you have multiple reports to test you'll have to login as the user and view the reports through their login to check RLS is applied correctly.

Hope this helps

Stuart

Thanks mate, exactly what I wanted to know

Cheers,
Josh

Helpful resources

Announcements
PBI Sept Update Carousel

Power BI September 2023 Update

Take a look at the September 2023 Power BI update to learn more.

Learn Live

Learn Live: Event Series

Join Microsoft Reactor and learn from developers.

Dashboard in a day with date

Exclusive opportunity for Women!

Join us for a free, hands-on Microsoft workshop led by women trainers for women where you will learn how to build a Dashboard in a Day!

Top Solution Authors
Top Kudoed Authors