Thanks for the question and using MS Q&A platform.
You’re correct that the index number [0] is causing the copy activity to return only the first row. To fetch all rows, you need to remove the index and use a dynamic expression to traverse through all the elements in the array.
Here are some steps you can follow:
- Use a Lookup Activity: You can use a Lookup activity with a JSON linked service to fetch the JSON data.
- Use a ForEach Activity: After fetching the JSON data, you can use a ForEach activity to loop through each element in the JSON array.
- Use Dynamic Expressions: Inside the ForEach activity, you can use dynamic expressions to parse the JSON data1. For example, you can use
@array(activity('Lookup1').output.value)
to parse the array of JSON. - Use a Copy Activity: Inside the ForEach loop, use a Copy activity to copy the parsed data to your desired destination.
Hope this helps. Do let us know if you any further queries.