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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
latheesh89
Helper II
Helper II

Update connection string for Imported PBIX file

Dear Techies,

 

I have to import PBIX files to multiple workspaces. Each workspace is pointing to diffrent Analysis Services DB and we have on premises gateway too. The Problem when I try to Import PBIX files using Import API. Connection string is same across all the workspaces. Which should not be the case, PBIX file should point to respective Analysis Services DB.

 

Is there a way to update the connection string for all the PBIX files in workspaces?

 

Please post the same code 

 

Thanks in Advance,

Latheesh

1 ACCEPTED SOLUTION
v-huizhn-msft
Microsoft Employee
Microsoft Employee

Hi @latheesh89,

Action that updates all of the connections strings in each data source only works for datasets that use direct query. We can not update the connect string for import mode. More details, please review this article.

If you connect database using Direct Model, you can update the connections string by referencing to this thread. In addition, I personally suggest you'd better post the developer related cases to Power BI developer community. You will get more professional support.

Best Regards,
Angelia

View solution in original post

3 REPLIES 3
v-huizhn-msft
Microsoft Employee
Microsoft Employee

Hi @latheesh89,

Action that updates all of the connections strings in each data source only works for datasets that use direct query. We can not update the connect string for import mode. More details, please review this article.

If you connect database using Direct Model, you can update the connections string by referencing to this thread. In addition, I personally suggest you'd better post the developer related cases to Power BI developer community. You will get more professional support.

Best Regards,
Angelia

Thanks Angelia

Hi @latheesh89,

You're welcome, it's my honor to help you. Please mark the right and helpful reply as answer, so more people will benefit from here.

Best Regards,
Angelia

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.