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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
adave
Frequent Visitor

Pass Credentials to Data Source

We are using Power BI report sever Aug 2018 version. I want to create a dashboard which can allow displaying charts dynamically based on user logged in. There are some reports/charts that need to be displayed but a supervisor is allowed to only view data for his/her employees.  I need to be able to pass on the user who logged on as a parameter to a stored procedure . The stored procedures accepts the user id and will return the relevant data.

Is this possible to achieve?

1 ACCEPTED SOLUTION
Anonymous
Not applicable

You can do more or less the same thing in the PBI Service. It gets more complicated if your data source is on premise as you have to setup the gateway but there areplenty of tutorials kicking around.

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

What you can do is pass the user credentials to the database by configuring the data source when you deploy the PBIX. If the databse is on a different server you will need to configure kerberos between the source database and the PBI-SSRS server so the credentials don't get dropped and your user arrives as "ANONYMOUS"

 

If you do that you don't need to pass the user ID as a parameter. You can just use the USER_NAME() function in T-SQL in your stored proc to get the logged in user name. If you use a Data Gateway then this probably gets vene more complciated in terms of Kerberos Setup.

 

These two links are useful when it comes to Kerberos related stuff.

 

https://www.youtube.com/watch?v=vCH8Fa3OpQ0

 

https://blog.dbi-services.com/power-bi-report-server-kerberos-setup/

Hello @Anonymous 

Thanks for your reply on this. I havent actually tried to use this as the project I needed this for was postponed. I am now again about look into it and had another question. At some point in future, we are considering to move to Power BI Service. If we were to use Power BI service for distribution of reports to users, how would the same issue of passing credentials work. Is there another option available with Power BI service to provide the same functionality?

Anonymous
Not applicable

You can do more or less the same thing in the PBI Service. It gets more complicated if your data source is on premise as you have to setup the gateway but there areplenty of tutorials kicking around.

Thanks @Anonymous 

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

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.