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
bartus1
Helper I
Helper I

Loop Through Several Values, Change API Call URL and Insert Into Table

Hi,

 

Have seen this thread, but I am still unclear what to do...

 

1.  API call - gets IDs wchih are stored in table1 - works great.  Table is neat and ready to go.

2.  Need to make another API call FOR EACH ID stored previously (table1), which will return items for each ID.

 

Eventually, will do 3rd call to get all detaisl for each item ID from #2.

 

Thanks.

1 ACCEPTED SOLUTION

Thanks a bunch v-ljerr-msf.

 

The 2nd article did help a lot.  Now, it seems very easy LOL.  I did run cirles around this.

 

Very much appreciated.

 

Bart

View solution in original post

2 REPLIES 2
v-ljerr-msft
Microsoft Employee
Microsoft Employee

Hi @bartus1,

 

Have you managed to create a function like below.

let functionName = (param1 as datatype) =>
let
 Source = Json.Document(Web.Contents("URL" & param1 & "/summary").
in
 Source
in functionName

If yes, then what you need to do next is adding a custom column in table1 that calls/invokes the function above. You should be able to find the detailed steps in following two articles. Smiley Happy

 

http://datachix.com/2014/05/22/power-query-functions-some-scenarios/

http://satalyst.com/power-query-creating-a-parameterized-function-in-m/

 

Regards

Thanks a bunch v-ljerr-msf.

 

The 2nd article did help a lot.  Now, it seems very easy LOL.  I did run cirles around this.

 

Very much appreciated.

 

Bart

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.