Forum Discussion

Newcolator's avatar
Newcolator
Icon for Helper II rankHelper II
1 year ago
Solved

Model error in report refreshes in service

Hello. When I refresh my report in PBI desktop I get this error because the data in the test area of Snowflake contains duplicates.     If I publish the un-refreshed report to the service an...
  • speedramps's avatar
    1 year ago

    Do you know that when you create a new PBIX in Power BI Desktop and publish to Power Bio Service that is creates 2 objects. The Dataset (semantic datamodel) and a the Report (pages of visuals).

    Possible reasons why you are getting different results :-

     

    1) In Power BI Desktop apply the changes and preview all, then apply changes and refresh.

    2) You have not checked the dataset refersh history, which will show the error. 


    3)The error you are getting is with the Dataset and not the report. So if you are just publishing the Report then you may have a different dataset on Power BI desktop and in the Power BI Service.

     

    4) The Power BI Service dataset as paramaters settings different to you Power BI desktop.

     

    5) Your are using a datasource with row level security. Your Power BI Desktop has credentials to the the duiplicate but your Power BI Service gateway credentials do not.

     

    Hope these help.

    Click, the thumbs up for trying.

    Click accept solution if any work.

    Thank you

     

  • v-ssriganesh's avatar
    v-ssriganesh
    1 year ago

    Hi Newcolator,
    Thank you for reaching out to the Microsoft fabric community forum.

    Unfortunately, no, there’s no built-in way to make the Power BI Service fail a dataset refresh due to model-level issues like duplicate keys unless those errors cause actual query or model breaking behaviour during refresh time.

    Please consider below workarounds:

    • In Power Query, you can add a data check that groups by CLAIM_KEY, counts occurrences, and identifies duplicates. If any are found, the query can trigger an error to stop the refresh. This ensures the refresh fails in both Desktop and Service when duplicate keys are present, helping you catch issues early before they affect your reports.
    • If your data is sourced through a Dataflow, you can build a validation step inside it and only load clean data into the report dataset.

    Thank you, speedramps & ajaybabuinturi for sharing valuable insights.

    If this information is helpful, please “Accept as solution” and give a "kudos" to assist other community members in resolving similar issues more efficiently.
    Thank you.