Forum Discussion

mirajvsen's avatar
mirajvsen
Regular Visitor
8 years ago

Handling datasource errors

Hi,

 

Is there a way to handle errors in the datasource like the following:

Requirement:

I have multiple datasource in multiple domains and would like to have a common power bi file to connect to them.

Power BI file is saved in my one drive with all datasource information and the output is an append query which is editted in the advanced query editior to combine all result sets.

When I am in one domain, I would like power bi desktop to try to connect to all datasources and ignore the ones which are unable to be connected since they are in different domains.

When i am in the next domain, the same should happen and the queries should execute on the SQL Servers which are able to be connected and ignore all the errors on the other datasources so that append can sucessfully combine all the data which are successfully retrieved from the current domain...

 

Thank a lot for the help...

 

2 Replies

Replies have been turned off for this discussion
  • v-juanli-msft's avatar
    v-juanli-msft
    Community Support

    Hi mirajvsen

    How does this error happen? What steps have you done?

    Do you use Windows credentials or SQL login to connect to the target SQL Server from Power BI Desktop? 

    You could follow steps in the blog to configure SQL Server to allow remote connections.

     

    Best Regards

    Maggie

    • mirajvsen's avatar
      mirajvsen
      Regular Visitor

      Hi v-juanli-msft,

       

      Thank you for the response...

      I understand that this error is caused due to a connectivity issue and I would like this to be handled using a "try" or some other method that exists in power BI. 

      My idea is to use the same power BI desktop file in different networks. 

       

      Please have a look at the following:

      DataSourceDomain
      Source1Domain1
      Source2Domain1
      Source3Domain1
      Source4Domain2
      Source5Domain2
      Source6Domain2

       

      I have an append query which will append the results from all the above mentioned datasources.

       

      The issue is,

      When I am in Domain1 and I refresh the power bi file, the append query tries to refresh all the datasources and the refresh fails for the datasources created in Domain2 and whole refresh process fails, because there is no connectivity to the sources in Domain2.

       

      Is there a way to overcome this situation by either configuring the power bi desktop to ignore the errornious sources in the append query or handle the error using a "try" or any other methods?