Forum Discussion

Cado_one's avatar
Cado_one
Icon for Resolver III rankResolver III
5 years ago
Solved

Unable to combine data - Please rebuild this data combination

Hi all,

 

I know there are already many topics regarding this issue but the common solution doesn't work in my case and I can't explain the reason.

When refreshing on Power BI Desktop everything is fine, when doing it on Power BI Service refresh fails and return the following error : 

  • [Unable to combine data] Section1/[Query]/[Last step of the query] references other queries or steps, so it may not directly access a data source. Please rebuild this data combination.

To work around this problem, I followed the following Ken Puls blog : https://www.excelguru.ca/blog/2015/03/11/power-query-errors-please-rebuild-this-data-combination/

 

However, even after staging queries as recommended the error is still present !

 

Here are my queries (Query 1's refresh is okay but the second and third queries's refresh give the error) :

                       Query1                                                      Query2                                       Query3

 

The source of Query3 is Query2 and the source of Query2 is Query1

 

Where did I miss somthing during my rebuild operations ?

 

Thanks in advance !

Best regards,

Cado

  • After some investigation, the solution was to put every stage used for the query into a single big query.

    It's not elegant but refresh is working this way..

5 Replies

  • What are the underlying data sources being used in any of the three queries you are showing?

    I also see a "Merged Queries" step in Query3, what is that merging?

     

    From my experience, I use staged queries for queries pulling from different sources that later need to be merged in a subsequent query

     

    Thanks,

    • Cado_one's avatar
      Cado_one
      Icon for Resolver III rankResolver III

      Hi blopez11 

       

      The source of the Query1 is an API web query

      In Query2, the "invoked custom function" apply an other API web query to each ID of the Query1

      In Query3, the "Merge queries" merge Query2 with an other API web query.

       

      In every stage API queries comes from the same website but the queries are different.

       

       

      • Cado_one's avatar
        Cado_one
        Icon for Resolver III rankResolver III

        After some investigation, the solution was to put every stage used for the query into a single big query.

        It's not elegant but refresh is working this way..

  • Cado_one,

     

    can you please clarify: was the refresh not working in the PBI service or even on PBI desktop? I'm having the same issue, also with nested API calls, have deployed the solution outlined by Ken Puls but the PBI service still took issue with it. Am I understanding you correctly that in your solution you put everything back into a single query? Isn't  that exactly the opposite of Ken's solution? I wish that there were a better, more surgical way to diagnose the culprit in these errors. Does calling a customer "Transform File" Helper Query-type function trigger this? 

     

    Regards,

     

     

    Henrik

    • Cado_one's avatar
      Cado_one
      Icon for Resolver III rankResolver III

      Hi waeltken 

       

      Indeed the issue came from the Service only.

      And yes I gathered every steps into a single query for the refresh to work fine in the Service.

      I can't explain the reason but I confirm that it solved the problem.

       

      Regards,

      Cado