Hi @Jan Cirpka ,
Welcome to Microsoft Q&A platform and thanks for posting your query in the forum.
As I understand your query, you are trying to filter out the data for which status parameter is 'closed' after the lookup activity returns the Output JSON .
The challenge here is that the value array is having data field which is also an array . You want to check the value of status parameter in each of the data fields. This can't be done using filter activity as it doesn't support wildcard. Also , we need to flatten the output JSON first in order to filter the underneath data.
For this scenario, my recommendation would be to use Data flow which gives us the ability to perform lots of transformations which is not possible using ADF activities.
- Copy the Lookup output in JSON file and create a dataset on top of the JSON file
- Use Source transformation and select the newly created JSON file as Dataset. Make sure to Select 'JSON settings' as 'Array of documents'
- Use Flatten transformation to flatten the array
- Use Filter transformation with query: equals(status,'closed') to filter records which has status value='closed'
Here is the gif you can refer to for implementation:
Hope this will help. Please let us know if any further queries.
------------------------------
- Please don't forget to click on
or upvote
button whenever the information provided helps you.
Original posters help the community find answers faster by identifying the correct answer. Here is how - Want a reminder to come back and check responses? Here is how to subscribe to a notification
- If you are interested in joining the VM program and help shape the future of Q&A: Here is how you can be part of Q&A Volunteer Moderators