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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
v-sadadi
Microsoft Employee
Microsoft Employee

Fetch Login information of the User

Hi Team,

 

Can we fetch the Login information of the User who logged in Power BI site and restrict the data shown in the Dashboard based on Login.

 

I have a scenario where I have a dashboard showing information of Users and this dashboard is shared across a group of people as a content pack/just shared. I want to restrict the data shown in the Dashboard/report is particular to the User who logged in to Power BI Site.

 

Any help on this is highly appreciated.

 

Thanks

Satya

1 ACCEPTED SOLUTION

Hi ashishrj,

 

I am able to do it in Power BI SSAS Tabular Model by defining Roles. I want the same functionality in Power BI Desktop.

 

I have a SSAS Tabular Model with a Role restricting the data by USERNAME() Funtion. Now I have imported this SSAS Tabular Model in Power BI Desktop and Published it on Power BI Site. But I did not find data restrictions with Role I defined in the Tabular Model. I am seeing all the users information.

 

When I open the Dataset/Report/Dashboard in Power BI Site with my login, the Data should get restricted to my UserId based on the role I defined in the Tabular model. The data should change according to the User who logged in to the Power BI Site.

 

Can we restrict User data on Power BI Site based on the Role?

 

Any help on this is highly appreciated.

 

Thanks

Satya

View solution in original post

5 REPLIES 5
ashishrj
Power Participant
Power Participant

@v-sadadi 1. No, you cannot fetch the login information for the user logged in to Power BI site.

2. This funtionality can be achieved in Power BI SSAS tabular modeling using row level security. 

dannio
Microsoft Employee
Microsoft Employee

Hello, is it still the case that you can't fetch a username inside of PowerBI Server?  thanks

Hi ashishrj,

 

I am able to do it in Power BI SSAS Tabular Model by defining Roles. I want the same functionality in Power BI Desktop.

 

I have a SSAS Tabular Model with a Role restricting the data by USERNAME() Funtion. Now I have imported this SSAS Tabular Model in Power BI Desktop and Published it on Power BI Site. But I did not find data restrictions with Role I defined in the Tabular Model. I am seeing all the users information.

 

When I open the Dataset/Report/Dashboard in Power BI Site with my login, the Data should get restricted to my UserId based on the role I defined in the Tabular model. The data should change according to the User who logged in to the Power BI Site.

 

Can we restrict User data on Power BI Site based on the Role?

 

Any help on this is highly appreciated.

 

Thanks

Satya

Bjoern
Continued Contributor
Continued Contributor

Use the direct connector to the AS Tabular. As far as I know, there is no row-level security in the PBI-File. 

 

You could also use Azure Sequel DB or SQL Server 2016 on-prem. Row-level security should also work there.

How can we achieve this?

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors