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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Anonymous
Not applicable

API change Analysis Services database in gataway data sources

Hi!

 

I'm trying programmatically change/update database in an Analysis Services Gateway data source - is there any way to do so?

 

I trying to to

   1. publish an PBIX file (with data source on premise Analysis Services database through Gateway)

   2. Remap the data source to a different database on same on premise server

 

Is this possible in Power BI API?

 

Or is it programmatically possible to change data source database in PBIX file before publishing it?

 

Any automated solution/workaround is appreciated 🙂

 

Kind regards,

 

NAJ

3 REPLIES 3
Eric_Zhang
Microsoft Employee
Microsoft Employee


@Anonymous wrote:

Hi!

 

I'm trying programmatically change/update database in an Analysis Services Gateway data source - is there any way to do so?

 

I trying to to

   1. publish an PBIX file (with data source on premise Analysis Services database through Gateway)

   2. Remap the data source to a different database on same on premise server

 

Is this possible in Power BI API?

 

Or is it programmatically possible to change data source database in PBIX file before publishing it?

 

Any automated solution/workaround is appreciated 🙂

 

Kind regards,

 

NAJ


@Anonymous

The datasource in gateway is configured according to the SSAS dataset connection string. So I guess you're requesting to change the connection string(contains server, database info) for the dataset, right? There's an REST API Set All Connections that can change the connection string , however it only supports DirectQuery dataset. And based on my test, SSAS live connection string is not treated as DirectQuery mode. So I'm that your request is to an dead end.

 

By the way, for the gateway REST API operations demo, you could reference this Knowledge base.

Anonymous
Not applicable

thank you for the reply Eric,

 

yes, i'm trying/requesting to programmatically change/update the connection string (server/database) of an SSAS On-prem live dataset/source. And/or remap a dataset to a different SSAS On-prem live source.

 

I have already tried most of the Gateway API functions (created new datasource , set all connections, etc.) - without any luck. 

 

Above request seems to be a limitation of the current REST API?

 

Kind regards,

 

NAJ

Anonymous
Not applicable

Did you ever find a work around for this?

 

Thanks, Shilpi

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.

Feb2025 Sticker Challenge

Join our Community Sticker Challenge 2025

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

Jan NL Carousel

Fabric Community Update - January 2025

Find out what's new and trending in the Fabric community.