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, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
K3ph4s
Regular Visitor

Error fetching data for this visual

Hi community,

I have a huge issue I do not know how to solve:

I have some BI models A,B,C

A BI Model is databased, that is linked into B and C as the "powerBI Sematic Model"

 

In my B and C models i have created some columns comparing data from A to B and/or C. In the editable file it works properly without any problem. However, everytime that i refresch automatically in the web browser i get this message:

 

 

I check both models and any of them have errors in the data compared.

Can anyone let me know how to fix this problem and solved the refresh step to show the data?

Regards

1 ACCEPTED SOLUTION
nandic
Super User
Super User

@K3ph4s , addition to my previous reply.
I created relationship between table from existing model with table from new source.
And after dataset refresh on Power BI Service, it throwed me the same error as in your side.

The issue is because i created relationship between table which is now in directquery model with table which is in import mode.

Then i created new table via directquery and when i tried to add new column, it throwed me error when i tried to use "LookupValue" function.
Which means this function doesn't work when using directquery mode.

So in your case, i think it is easier to take pbix file that is already published for model A, duplicate it and then within this new pbix file to add tables for model B and model C.
So not to have composite model (link to published dataset + new data sources), but to have all tables within new pbix file (new dataset).

Cheers,
Nemanja Andic

View solution in original post

7 REPLIES 7
nandic
Super User
Super User

@K3ph4s , addition to my previous reply.
I created relationship between table from existing model with table from new source.
And after dataset refresh on Power BI Service, it throwed me the same error as in your side.

The issue is because i created relationship between table which is now in directquery model with table which is in import mode.

Then i created new table via directquery and when i tried to add new column, it throwed me error when i tried to use "LookupValue" function.
Which means this function doesn't work when using directquery mode.

So in your case, i think it is easier to take pbix file that is already published for model A, duplicate it and then within this new pbix file to add tables for model B and model C.
So not to have composite model (link to published dataset + new data sources), but to have all tables within new pbix file (new dataset).

Cheers,
Nemanja Andic

@nandic thanks... this is something it must be reported to Microsoft.
So i have done everythin correct.

The solution is to add the data base of the Model A into every other moderls B, C....


Thanks

@K3ph4s yes, you have done everything as it should be (from developer view).
However, Microsoft is pretty much aware that a lot of DAX functions do not work in DirectQuery. They mention it always when presenting directquery.

And yes, i agree with you that if they allow us to combine live data and imported data in desktop app, it should be fine on Service. On the other hand, if it was easy, they would make it work.


nandic
Super User
Super User

Hi @K3ph4s , i did test on my side.
Connected to existing semantic model, added locally additional table, created relationship, created same dax expression as above, everything works fine.

This is the warning that i get before publish:

nandic_0-1726656279293.png

As connection to published dataset becomes directQuery after adding locally new sources, maybe it hits some of these limitations: https://learn.microsoft.com/en-us/analysis-services/tabular-models/directquery-mode-ssas-tabular?vie... 

Additinaly, calculated tables are not supported, do you have any calculated tables in this composite model?

Finally, could you try rewriting DAX, to use Related instead of LookupValue or creating relationship?

Here is full text with composite model limitations: https://learn.microsoft.com/en-us/power-bi/transform-model/desktop-composite-models




nandic
Super User
Super User

@K3ph4s , two more questions:
1) As i have not used Autodesk connector earlier, did you try to publish data only from this connector to Power BI Service? I've heard that some connectors work in desktop app, but not on Power BI Service
2) Power BI dataset A is published to Power BI Service. Now you have new Power BI file (new dataset) where you connect live to published dataset A and then you additionally add data from Autodeck, etc in that new dataset (you create local model)? Everything works fine locally until you publish it to Power BI Service.
Then you can see errors on reports because it requires dataset refresh.
What type of error do you get when you try to refresh that new dataset?

Cheers,
Nemanja Andic

K3ph4s
Regular Visitor

Morning @nandic  thanks for your response,

Credentials are up to date and reviewed.

let me explain it better:
Model A: contains databases from Excel that will need to be included in models B and C as is the standard information to be compared with models B and C (project models)

Model B & C: Project Model with information from the specific project. These models contain information from a data cloud source connection with Autodesk connector (API to connect the Autodesk database). These models also contain the information from Model A (connected through Power Bi Semantic Model). Then I create many new columns comparing  the data between MOdel B (project Data) against Model A (Standard Data),

K3ph4s_0-1726480521657.png

 


Formula for example:

 

QA_ReviewsSiteName = IF(
    ISBLANK(
        LOOKUPVALUE('Model A'[Site Code],'Model A'[Site Code],'Model B'[Site Name])
    )
    ,"No"
    ,"Yes"
)

 

The results of this new columns are use to show charts of QA, such as:

K3ph4s_1-1726480587113.png

The charts and the formulas work perfectly in the editable Model. However, when I publish this data to the cloud, then, I receive the following issues:

K3ph4s_2-1726480654347.png

and see details shows:

K3ph4s_3-1726480683722.png

 

 

Hopefully, it is a clear explanation

 

Regards

 

nandic
Super User
Super User

Hi @K3ph4s ,
As the issue is on Power BI Service side (not on Power BI Desktop app), could you make sure you added all credentials needed on Power BI dataset settings?

If that is not the case, could you share mode details, example of models A and B?
How are they connected?
How are these calculated columns created (via DAX or Power Query)?
Are these calculated columns user then for some other calculations?

It may be that calculated columns is created via DAX, but it used as a Key to connect some tables in Power Query so it is confused.

The order of operations is important, in this case it seems that some part of data is not fetched successfully which leads to error because it should be used on another place in data model.

Cheers,
Nemanja Andic

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

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

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

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! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

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