Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi,
still a newbie toPower BI. Is there any way to create a connection object that contains the database details, username,pwd that can then be shared /used with many reports ? If I change my data source I want to only update one connection object and my many reports would switch over....
Thanks
Solved! Go to Solution.
Hello @Anonymous
the login data is stored in the profile. So there is only the need to maintain it once.
If this post helps or solves your problem, please mark it as solution (to help other users find useful content and to acknowledge the work of users that helped you)
Kudoes are nice too
Have fun
Jimmy
Hello @Anonymous
the connection details as ID/Password can't be hardcoded in a M-Query. They will be stored on your profile, when you execute the query and therefore not be passed in the file.
Hope it helps
Jimmy
thanks Jimmy,
still confused here, probably need to do some more playing around on this. If I want to use a generic Db account and could be connecting to any type of Db (Oracle, Netezza, Greenplum...) where would these details be stored, not sure where this 'profile' you mention sits.
Just as background, I stood up a Windows VM with SQL Server and installed Power BI just to get a flavour of this tool and compare with Qlik, OBIEE, Bus Objects....all these tools can hold connection detail outside of a report and are simply referenced.
Thanks
Hello @Anonymous
Power Query - alias M - is a functional programming language. Therefore there are available for a lot of data sources different functions, that require parameters, like server or whatever. For some data sources is possible to maintain queries in SQL/MDX/DAX and other additional information. This all you can hardcode. However, IDs or passwords can not be hardcoded. They have to be set up by the different user, refreshing the query.
Hope now is clearer
Jimmy
Thanks,
think I'm getting the idea. I asume taht if I create a report against an Oracle Db and share the Power BI file, when they chose to refresh the data it will prompt them for username.pwd. Will that be saved somewhere or will it always prompt on each refresh ?
Also reading up about PBID files ...
Appreciate this.
Hello @Anonymous
the login data is stored in the profile. So there is only the need to maintain it once.
If this post helps or solves your problem, please mark it as solution (to help other users find useful content and to acknowledge the work of users that helped you)
Kudoes are nice too
Have fun
Jimmy
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!