Reply
Highlighted
Member
Posts: 62
Registered: ‎01-08-2018

How to switch between Development and Production servers when using Enterprise Gateways?

Hi,

 

I wanted to understand how the Gateway works when working with development and production data/servers. 

We have only one Enterprise gateway installed in a separate server (lets say, Gateway1). This gateway has 2 "Data Source" conections - one pointing to Development data/server and the other pointing to production data/server.

 

Here is my scenario-

I created a report using the development data in Power BI Desktop which means my connections are now pointing to development data/server. I publish this report to the Power BI Service workspace and apply the Gateway connections for testing.

 

After testing is completed in Power BI Service workspace, how do I change the connections to production data/server???

 

Do I have to go back to Power BI Desktop (Data source settings) and change/point it to production server and then re-publish the report again?

Or 

Is there a way for me to switch to production data/server in Power BI Service?

 

In Power BI Service, the only thing I see is the Gateway Name (under Datasets settings) and nothing that shows developement or production data source name to switch between them.

 

2018-08-31_1004.png

 

Any insight is greatly appreciated. Thanks!

Super User
Posts: 3,484
Registered: ‎06-25-2015

Re: How to switch between Development and Production servers when using Enterprise Gateways?

@BBIUser I haven't done this yet personally, but you should be able to achieve this by using the PowerShell commands.

Have a look at this:

https://github.com/Azure-Samples/powerbi-powershell

Near SE WI? Join our PUG MSBIWI
Community Support Team
Posts: 2,906
Registered: ‎02-06-2018

Re: How to switch between Development and Production servers when using Enterprise Gateways?

Hi @BBIUser,

 


 

 After testing is completed in Power BI Service workspace, how do I change the connections to production data/server???

 

Do I have to go back to Power BI Desktop (Data source settings) and change/point it to production server and then re-publish the report again?

Or 

Is there a way for me to switch to production data/server in Power BI Service?

 

In Power BI Service, the only thing I see is the Gateway Name (under Datasets settings) and nothing that shows developement or production data source name to switch between them.

 

 


 

 

For your requirement, I found this blog Using the Power BI Service Parameters to change connection strings could help you.

 

Best Regards,

Cherry

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Member
Posts: 62
Registered: ‎01-08-2018

Re: How to switch between Development and Production servers when using Enterprise Gateways?

[ Edited ]

@Seth_C_Bauer Thanks for sharing the link, I still din't try what you shared as Cherry's solution was closer to what I was trying to achieve.

 

@v-piga-msft Cherry, Thanks for sharing the blog!

I was able to partially reproduce what was given in the blog. I am missing something here to get the actual results.

 

Let me give my scenario:

- I have just 1 dataset in Power BI Desktop. I want to use this same dataset to create reports and switch from development to production. 

- Used Import connection.

- No SQL Statement since I am connecting to just 1 table directly.

- I have created 1 parameter for Server Name where the 'Current Value' is having Development Server information.

- I have created 1 parameter for Database Name which should be the same for production.

 

2018-09-19_1320.png

1) Should I create another Parameter with Production Server information?

2) Even if I publish with 2 parameters (Dev and Prod), all I can see only the parameter which was selected, saved and published through Power BI Desktop. 

I cannot change the Parameter in Power BI Service.

2018-09-19_1356.png

3) Where should I declare the @@ServerName, since I am not using the SQL Statement instead have imported the table?

 

Thanks again!

Visitor
Posts: 1
Registered: ‎10-24-2018

Re: How to switch between Development and Production servers when using Enterprise Gateways?

You need to select a type for your parameter other than any. The parameters remain greyed out if Any is selected. Try a type of Text.