Forum Discussion
Table Level Security
- 1 year ago
HI ribisht,Thanks for the clarification!
Giving users direct access to the Google Sheet would defeat the purpose of security. In Power BI, if a user cannot access the data source, the visual fails because the dataset cannot be loaded.Connect the Google Sheet to Power BI using a service account that has access to the sheet, so the data loads centrally and not based on individual user permissions. Then apply Row-Level Security (RLS) and use conditional DAX measures to show blank values for columns from Table B for users without access. This way, users will see the full visual with restricted data showing as blank, without exposing the actual Google Sheet or its contents.
Glad I could assist! If this answer helped resolve your issue, please mark it as Accept as Solution and give us Kudos to guide others facing the same concern.
Thank you.
Hi ribisht ,
In Power BI, when you apply Table-Level Security (TLS) and restrict access to a table (e.g., Table B), any visual referencing that table will not display for users without access—this is standard behavior, as Power BI blocks access at the object level. To address the requirement of displaying the full visual with columns from Table B appearing as blank/null for restricted users, you can implement a custom solution using a user access table and conditional DAX measures:
To resolve the issue we need to create a UserAccess table mapping each user to a flag indicating whether they have access to Table B. For each column from Table B in the visual, create a DAX measure that conditionally returns the value only if the user has access, like this:
TableB_Column1_Display =
IF (
LOOKUPVALUE(UserAccess[HasAccessToTableB], UserAccess[UserPrincipalName], USERPRINCIPALNAME()) = TRUE,
SELECTEDVALUE(TableB[Column1]),
BLANK()
)
Replace the Table B columns in your visual with these DAX measures. Finally, apply Row-Level Security (RLS) on the UserAccess table to filter data based on the logged-in user:
UserAccess[UserPrincipalName] = USERPRINCIPALNAME()
This ensures that users without access to Table B see blank values, while those with access can view the data.
If this solution worked for you, kindly mark it as Accept as Solution and feel free to give a Kudos, it would be much appreciated!
Thank you for using Microsoft Fabric Community Forum.
When I say "don't have access," I’m referring to the user being unable to access the Google Sheet that serves as the data source.