Forum Discussion

HesamMontazer's avatar
HesamMontazer
New Member
11 months ago
Solved

This dataset includes a dynamic data source. Since dynamic data sources aren't refreshed in the Powe

Hello, I am trying to connect my weclapp account to powe bi services. But I get this error: This dataset includes a dynamic data source. Since dynamic data sources aren't refreshed in the Power BI ...
  • MasonMA's avatar
    11 months ago

    HesamMontazer 

     

    Your structure with RelativePath and Query is exactly the supported exception on Microsoft documents.
    But you must ensure BaseURL is a literal string, not a parameterized or function-passed value

     

    You may try below adjusted M code (Hardcode the BaseURL string directly inside Web.Contents instead of keeping it in a variable)

    WebCall = Json.Document(
    Web.Contents(
    "https://brandgarage.weclapp.com", // hardcoded
    [
    RelativePath = "webapp/api/v1/salesOrder",
    Query = QueryParams,
    Headers = [
    AuthenticationToken = token,
    #"Content-Type" = "application/json",
    Accept = "application/json"
    ]
    ]
    )
    ),

  • Shahid12523's avatar
    11 months ago

    Power BI Service blocks refresh for queries with dynamic URLs. Your use of Web.Contents with changing query parameters (like StartDate, EndDate, Page) makes the source dynamic.
    Fix:
    Make the URL structure static by keeping the same field names in the Query record, even if some values are null. That way, Power BI can validate the source at design time.