Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
I have been using the Rest API to publish PBIX files to PowerBI.com. Part of this process was setting the connection strings to the production instance. I struggled with the documentation, as we are using an on-premise data source with the enterprise gateway.
I spent many hours troubleshooting why i was getting an error
Solved! Go to Solution.
I have been using the Rest API to publish PBIX files to PowerBI.com. Part of this process was setting the connection strings to the production instance. The documentation doesnt say much around using an on-premise data source with the enterprise gateway.
I spent many hours troubleshooting why i was getting this error
The example connectionstring that is used is this:
"data source=MyAzureDB.database.windows.net;initial catalog= Sample2;persist security info=True;encrypt=True;trustservercertificate=False"
I couldnt get that to work, i got it to work using the following format:
"data source=mylocaldbinstance;initial catalog=localdb;persist security info=False" .
Hopefully this helps others who get stuck on this.
I have been using the Rest API to publish PBIX files to PowerBI.com. Part of this process was setting the connection strings to the production instance. The documentation doesnt say much around using an on-premise data source with the enterprise gateway.
I spent many hours troubleshooting why i was getting this error
The example connectionstring that is used is this:
"data source=MyAzureDB.database.windows.net;initial catalog= Sample2;persist security info=True;encrypt=True;trustservercertificate=False"
I couldnt get that to work, i got it to work using the following format:
"data source=mylocaldbinstance;initial catalog=localdb;persist security info=False" .
Hopefully this helps others who get stuck on this.
@williamd wrote:
I have been using the Rest API to publish PBIX files to PowerBI.com. Part of this process was setting the connection strings to the production instance. The documentation doesnt say much around using an on-premise data source with the enterprise gateway.
I spent many hours troubleshooting why i was getting this error
The example connectionstring that is used is this:
"data source=MyAzureDB.database.windows.net;initial catalog= Sample2;persist security info=True;encrypt=True;trustservercertificate=False"
I couldnt get that to work, i got it to work using the following format:
"data source=mylocaldbinstance;initial catalog=localdb;persist security info=False" .
Hopefully this helps others who get stuck on this.
Great to hear you could finally get this to work, was the API Set All Connections called in your case?
Hi,
I am trying the similar thing. Using Import API I have imported set of PBIX files to PBI Service. Now I would need to update the connection string for all the imported ones. Connection string varies for different App workspace.
I have been using the Rest API to publish PBIX files to PowerBI.com. Part of this process was setting the connection strings to the production instance. I struggled with the documentation, as we are using an on-premise data source with the enterprise gateway.
I spent many hours troubleshooting why i was getting this error, after following the apery sample:
"data source=MyAzureDB.database.windows.net;initial catalog= Sample2;persist security info=True;encrypt=True;trustservercertificate=False"
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
11 | |
6 | |
4 | |
2 | |
2 |
User | Count |
---|---|
4 | |
4 | |
3 | |
3 | |
3 |