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

Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!

Reply
Mohamadmonem
Advocate I
Advocate I

Changing server/database for multiple semantic models without republishing

Hi Everyone!

We have multiple semantic models in Power BI Service connected through an On-premises Data Gateway.

If the database server address or database name changes, is there a way to update the connection centrally without opening and republishing each semantic model?

Can this be handled by:

  • Updating the Gateway data source only?

  • Using parameters?

  • Using the REST API (Update Datasource)?

  • Or is updating each semantic model individually unavoidable?

We want to avoid updating each semantic model one by one.

1 ACCEPTED SOLUTION
MohdZaid_
Helper I
Helper I

Hey @Mohamadmonem  , 

 

You can use the Update Datasources REST API to update multiple semantic models programmatically:

 

https://learn.microsoft.com/en-us/rest/api/power-bi/datasets/update-datasources

 

This is ideal if:

You have many models

You want to avoid manual work

You’re comfortable using PowerShell or automation

 

If it solved your issue, feel free to mark it as the solution so others can benefit too.

 

Thanks for being part of the community.

View solution in original post

3 REPLIES 3
MohdZaid_
Helper I
Helper I

Hey @Mohamadmonem  , 

 

You can use the Update Datasources REST API to update multiple semantic models programmatically:

 

https://learn.microsoft.com/en-us/rest/api/power-bi/datasets/update-datasources

 

This is ideal if:

You have many models

You want to avoid manual work

You’re comfortable using PowerShell or automation

 

If it solved your issue, feel free to mark it as the solution so others can benefit too.

 

Thanks for being part of the community.

cengizhanarslan
Super User
Super User

You can define parameters for your Server and Database info in PowerQuery and use those parameters as a part of table source. However you would still need to individually change parameters in semantic model options in power bi service.

_________________________________________________________
If this helped, ✓ Mark as Solution | Kudos appreciated
Connect on LinkedIn
AI-assisted tools are used solely for wording support. All conclusions are independently reviewed.

Thanks for your reply.

I understand that parameters can be used if they are defined in Power Query from the beginning.

 

However, in our case, the semantic models were not originally built with parameters. That means we would need to modify and republish each model to introduce them.

 

Is there any alternative way to update the server/database connection centrally without rebuilding and republishing each semantic model?

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

Vote for your favorite vizzies from the Power BI World Championship submissions!

Sticker Challenge 2026 Carousel

Join our Community Sticker Challenge 2026

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 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.