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

Get certified in Microsoft Fabric—for free! For a limited time, the Microsoft Fabric Community team will be offering free DP-600 exam vouchers. Prepare now

Reply
ben1
New Member

Connect to multiple Salesforce orgs at the same time?

I am testing Power BI. The Salesforce connector works well.

 

However, we have multiple Salesforce orgs and I am wodnering if it is possible to connect to each of them and pull data from each org into a single dashboard?

 

For example, if I pull in a report on all Opportunities, there will be some overlap of customers. If two opportunites are linked to a contact with the same email address (even though in different salesforce orgs), then can Power BI report on this?

 

Thanks

11 REPLIES 11
kwdavis7
Frequent Visitor

Finally figured it out! The key is when putting in the url for the custom option to connect that you use the format https://[yourdomain].my.salesforce.com instead of what you may actually see in the url when logging into Salesforce. For example when I log into Sales my url looks like the image below (domain blocked out for security).

kwdavis7_0-1645620595782.png


But when I go to Get Data > Salesforce Reports > URL Custom I have to type it in as https://[yourdomain].my.salesforce.com
Basically changing ".lightning.force.com" to ".my.salesforce.com"

Hope that helps.

this is genius!

bd92
Frequent Visitor

I had the same issue for my dataflows and did something similar to what is suggested in some responses above, but in the M-code.

 

By default, Power Query will produce the following code:

Source = Salesforce.Data(),

 

You can replace by:

Source = Salesforce.Data("https://yourdomainname.my.salesforce.com"),

 

Replacing "yourdomainname" with yours. Once this is done, Power Query will ask to authentificate, and redirect you to https://yourdomainname.my.salesforce.com.

 

If you have multiple Salesforce org under the same sub-domain as stated above (e.g. NA01.salesforce.com), a solution can be to setup "My Domain" feature in Salesforce setup. Doing so, you will choose the subdomain you want, that has to be unique.

Then, you will be able to put this unique login url in you m-code.

Anonymous
Not applicable

Running into the same issue. 

I can only login to my instances by using https://login.salesforce.com as the default URL to login. I can do that and log in with username and password 1, and get the data that is associated with that account. I can do that and log in with username and password 2, and get the data that is associated with that account. But I cannot create one connection where I login with username and password 1 and a separate connection where I log in with username 2 in order to to pull the data from both logins. 

pablobarra
Advocate I
Advocate I

Hi @ben1

 

You should be able to do it by using \get data\from Salesforce and seect "custom" instead of "production".

"Custom" option allows you to connect to a Sandbox and to Production.

You need to add the url of your "production" environment (like https://eu14.salesforce.com/)

If you have more than one instance of SFDC in the same environment, you can use "login.salesforce.com", "emea.salesforce.com, etc.

Pablo

Hi -

I have 3 Salesforce orgs to connect and I unfortunately selected "Production" while connecting the fist one. I tried to export the dataflow to json and import it as a Model into a second dataflow but PowerBI doesn't give me the option to select the credentials for each org.

What am I supposed to do? Recreate the (long) dataflow coping and pasting the M code for each table OR there 's a central place where to manage Salesforce org's credentials in PBI service?

Thanks!

Andrea

Hi @pablobarra

 

I tried that. When I click Get Data -> Salesforce for the first time, it asks me to login, and I can then connect without trouble.

 

However, if I go to Get Data -> Salesforce for a second time, it automatically uses my existing credential and doesn't give any option to enter a different one.

Hi @ben1

Did you selected "Custom" when selecting the environment?

Select Custom and use different URL each time, for example https://login.salesforce.com, https://e10.salesforce.com/, etc.

You will be able to find you Salesforce URL in the UI. 

Use different URL, for example login.salesforce.com and emea.salesforce.com can work with your instance, try if that is the case, and if so, you can use them as different "custom" connections.

Pablo

 

 

1) Log into your salesforce instance.

2) Take note of the subdomain of the url after you login.  We will use this in a later step... Example:  https://na78.lightning.force.com

3) Click Get Data

4) type Salesforce into search

5) Click on Salesforce Objects.  A window will pop up

6) Choose the Custom radio button and then type this into the text field  https://na78.salesforce.com (using whatever subdomain is right for your instance of Salesforce).  This will take you through the login process again so you can access more than one instance of Salesforce

Anonymous
Not applicable

Hi - I have two SFDC orgs...both of them on the same instance or sub-domain (i.e. NA01). Therefore I can't use NA01.salesforce.com to login. If I connect to both of them in one report via login.salesforce.com I can pushlish the report with the data from the two different instances, however once I refresh the data via the service, since the path to login for both is login.salesforce.com...it consideres it one datasource and only allows me to populated one set of credentials instead of two.

 

Has anyone encountered a solution to this??

Anonymous
Not applicable

We are running into the same issue with multiple SF orgs. Were you able to find a solution?

Helpful resources

Announcements
OCT PBI Update Carousel

Power BI Monthly Update - October 2024

Check out the October 2024 Power BI update to learn about new features.

September Hackathon Carousel

Microsoft Fabric & AI Learning Hackathon

Learn from experts, get hands-on experience, and win awesome prizes.

October NL Carousel

Fabric Community Update - October 2024

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

Top Solution Authors
Top Kudoed Authors