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
Anonymous
Not applicable

Direct Query Report - RLS User getting 401 error when accessing in App Workspace or Shared Report

We are running into an error with a report developed with DirectQuery mode on a SQL Server Connection.  We have configured the report RLS with two security groups:
  • Group A which is filtering on a user table with UserName = UserPrincipalName()... user table is tied to a location which filters the reports by location
  • Group B which is has no dax filters giving anyone in this group access to all locations
 
Admins of the App Workspace can see everything fine as if they are unfiltered
Members that are assigned to security Group A and security Group B are able to see the report, but they get errors in all tiles.
 
Status Code401
Activity ID3ead3220-90c5-4c92-b721-847c893bb8a1
Correlation IDaae44a61-de15-c843-bb10-088def95092e
Request ID1f4739f6-4d64-bba8-9347-7ee8c524be88
TimeMon May 14 2018 14:23:39 GMT-0500 (Central Daylight Time)
Version13.0.5248.195
 
Can someone please help?
 
Thanks,
 
Bryan
5 REPLIES 5
GilbertQ
Super User
Super User

Hi there,

Has it ever worked with going down to the SQL Server source?

I have only done Direct Query RLS to an SSAS Server, so not exactly sure how it would work with SQL Server





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!







Power BI Blog

Anonymous
Not applicable

It works as expected in Power BI desktop when testing the Security Roles. Not sure why it wouldn’t work if security can be applied with DAX on a table.

Hi there

Have you added the users to the Security Role in the Power BI Service?




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!







Power BI Blog

Anonymous
Not applicable

Thanks for your reply and working through this with me. I was under the assumption this was controlled by AD Security groups named the same as the role you create. Where are users added to the role in PBI Service.

Hi there,

 

Ok that is for imported datasets, I forgot that yours was DirectQuery.

 

The only other thing to check for is to ensure that your gateway is mapping the usernames correctly through to your SQL Server source.

 

I would run Query Profiler on your SQL database and check to see if it is passing through the correct username?





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!







Power BI Blog

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.

Top Solution Authors
Top Kudoed Authors