Forum Discussion
gjross
Advocate II
10 years agoConnection String for Embedded report which uses DirectQuery
I have a PBIX which uses a Direct Query to a SQL Azure database. I have followed the steps in https://azure.microsoft.com/en-gb/documentation/articles/power-bi-embedded-get-started-sample to create a...
- 10 years ago
Yes that will work as it retains the connection string from the .pbix file you upload. If you want to programmatically change the connection string (e.g. to switch between DEV/TEST/LIVE) then I believe this should help?
https://msdn.microsoft.com/en-us/library/azure/mt711505.aspx
sundar
9 years agoNew Member
While designing the report use Direct query method instead of Import in Power BI desktop.
And then import the Pbix file using Provisionsample command line .
Finally update the dataset using the following connection string format:
"Data Source=xxxx.database.windows.net;Initial Catalog=dbname;User ID=xxx;Password=xxxx;"
It worked well for me. Hope it will help.
Thank you.