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

Join the FabCon + SQLCon recap series. Up next: Power BI, Real-Time Intelligence, IQ and AI, and Data Factory take center stage. All sessions are available on-demand after the live show. Register now

Reply
Anonymous
Not applicable

API call through no numeric parameters

Hello.

I have a problem working wirth API.

 

I've read many post, but can't find a solution to my problem.

 

I need to obtain information fron different APIs, but get error.

 

This is what i'm doing:

 1. I get information from the first API and perform the transformations.

Script name: query1

Esteban__2-1621452049755.png

Esteban__3-1621452082869.png

 

2. Once i have the table ready, I modify the query by:

           - Convert the query into function.

           - Create an API parameter (PRY as text)

Esteban__5-1621452373439.png

3. I have all the text parameters in another table (ID_Proyectos)

table name: Proyects

Esteban__1-1621451772005.png

 

4. I select a blank query from sources and type in a new script, which looks like this

Script name: Results

Esteban__6-1621452883084.png

(in this script I call the function (query1) and applies the function to each proyect ID from te table Proyects).

 

I should get all the information, but instead I get an error for each ID Proyects.

 

Esteban__7-1621453148179.png

 

I'm really stuck in this issue, because all the information I find is for loops with a number of pages or until get an specific message, but can't find any information about a loop through non numeric parameter.

 

I'll really appreciate your help.

Regards

1 ACCEPTED SOLUTION
Anonymous
Not applicable

HI @Anonymous,

I'd like to suggest you create a blank query table to reference the 'Proyects' table, then you can add a custom column to invoke custom function based on each 'ID Proyects':

let
    Source = Proyects,
    AddColumn =
        Table.AddColumn(
            Source,
            "Custom",
            each query1([ID_Proyects])
        )
in
    AddColumn

Regards,

Xiaoxin Sheng

View solution in original post

1 REPLY 1
Anonymous
Not applicable

HI @Anonymous,

I'd like to suggest you create a blank query table to reference the 'Proyects' table, then you can add a custom column to invoke custom function based on each 'ID Proyects':

let
    Source = Proyects,
    AddColumn =
        Table.AddColumn(
            Source,
            "Custom",
            each query1([ID_Proyects])
        )
in
    AddColumn

Regards,

Xiaoxin Sheng

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

Check out the April 2026 Power BI update to learn about new features.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

FabCon and SQLCon Highlights Carousel

FabCon &SQLCon Highlights

Experience the highlights from FabCon & SQLCon, available live and on-demand starting April 14th.