Forum Discussion
API Loop
- Anonymous1 year ago
Hi halll_sc
You can perform the SQL query activity after the Copy Data activity. Add an sql query to calculate whether 500 records are returned.
How to use Script activity - Microsoft Fabric | Microsoft Learn
Regards,
Nono Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Do it the other way round. Check if the current call has returned 500 rows. If yes, make the next call. If no, exit the loop.
Thank you for the input but the API response doesnt return a row count , so to go down that road I think I would have to perform the copy activity and get the row count of records inserted into the table and if == 500 then call the next API. Or is there another way to return the record count returned from the endpoint ?