Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
MithSingh
Frequent Visitor

Can't save dataflow "One or more tables references a dynamic data source."

Hi Everyone,
 
I can't able to save it, getting an error. please help me with this.
 
let
  Source = List.Generate( () =>

        [ URL = "https://LPF.api.goflow.com/v1/orders?filters[date:gte]=2023-03-27T00:00:00Z" , Result = Json.Document(Web.Contents(URL,[Headers=[Authorization="Bearer xxxxxxxxxxxxxxxxxxxxxxx"]])) ],

        each [URL] <> null,

        each [ URL = [Result][next] , Result = Json.Document(Web.Contents([URL],[Headers=[Authorization="Bearer xxxxxxxxxxxxxxxxxxxxxxx"]])) ]

    ),
  #"Convert to table" = Table.FromValue(Source),
  #"Expanded Value" = Table.ExpandRecordColumn(#"Convert to table", "Value", {"URL"}, {"URL"})
in
  #"Expanded Value"
 
 
I also tried this M query, but I am also getting an error "Expression.Error: We cannot convert a value of type Binary to type Text."
 
let
  Source = List.Generate( () =>

        [ URL = Web.Contents(
        [
                RelativePath= "v1/",
                Query=[
                        orders= "filters[date:gte]=2023-03-27T00:00:00Z"
                ]
        ]

) , Result = Json.Document(Web.Contents(URL,[Headers=[Authorization="Bearer xxxxxxxxxxxxxxxxxxxxxxx"]])) ],

        each [URL] <> null,

        each [ URL = [Result][next] , Result = Json.Document(Web.Contents([URL],[Headers=[Authorization="Bearer xxxxxxxxxxxxxxxxxxxxxxx"]])) ]

    ),
  #"Convert to table" = Table.FromValue(Source),
  #"Expanded Value" = Table.ExpandRecordColumn(#"Convert to table", "Value", {"URL"}, {"URL"}),
  #"Transform columns" = Table.TransformColumnTypes(#"Expanded Value", {{"URL", type text}})
in
  #"Transform columns"
 
Please help me with this.
 
 
4 REPLIES 4
lbendlin
Super User
Super User

 

 

 Source = List.Generate( () =>

        URL = Web.Contents(
        "https://LPF.api.goflow.com/",
        [
                RelativePath= "v1/orders",
                Query=[
                        #"filters[date:gte]"="2023-03-27T00:00:00Z"
                ]
        ]
    ),
...

 

 

Thank you,

 

I tried this M query:

 

let
    Source = List.Generate( () =>

        [ URL = Web.Contents(
        [
                RelativePath= "v1/orders",
                Query=[
                        #"filters[date:gte]"="2023-03-27T00:00:00Z"
                ]
        ]
    ) , Result = Json.Document(Web.Contents(URL,[Headers=[Authorization="Bearer xxxxxxxxxxxxxxxxxxxxxxx"]])) ],

        each [URL] <> null,

        each [ URL = [Result][next] , Result = Json.Document(Web.Contents([URL],[Headers=[Authorization="Bearer xxxxxxxxxxxxxxxxxxxxxxx"]])) ]

    )
   
in
   Source
 
getting an error "Expression.Error: We cannot convert a value of type Binary to type Text."

Hi @MithSingh ,
try removing the square brackets around URL in the last step like so:

 

let
    Source = List.Generate(
        () => [
            URL = Web.Contents(
                "https://LPF.api.goflow.com/", 
                [RelativePath = "v1/orders", Query = [#"filters[date:gte]" = "2023-03-27T00:00:00Z"]]
            ), 
            Result = Json.Document(Web.Contents(URL, [Headers = [Authorization = "Bearer xxxxxxxxxxxxxxxxxxxxxxx"]]))
        ], 
        each [URL] <> null, 
        each [
            URL    = [Result][next], 
            Result = Json.Document(Web.Contents(URL, [Headers = [Authorization = "Bearer xxxxxxxxxxxxxxxxxxxxxxx"]]))
        ]
    )
in
    Source

 

Imke Feldmann (The BIccountant)

If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!

How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries

already tried, and again tried it, getting an error "Expression.Error: We cannot convert a value of type Binary to type Text."

Helpful resources

Announcements
Fabcon_Europe_Social_Bogo

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

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

PBI_Carousel_NL_June

Fabric Community Update - June 2024

Get the latest Fabric updates from Build 2024, key Skills Challenge voucher deadlines, top blogs, forum posts, and product ideas.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

Top Solution Authors
Top Kudoed Authors