The array with lesser items has 38 items and the total in Extra items is 40 instead of becoming an array with 2 items, it takes all the 40 items. So something with the comparing isn't working. Or am i comparing the wrong array in the above picture?
The array with lesser items has 38 items and the total in Extra items is 40 instead of becoming an array with 2 items, it takes all the 40 items. So something with the comparing isn't working. Or am i comparing the wrong array in the above picture?
Loved this solution. Thanks for sharing it!
This should work too.
Going through this right now with an array of group members vs items in a sharepoint list... No matter how I write it, my condition never picks up that the group member already exists in the list and runs my flow against every member in the group. Which is problematic because the flow is written to create a list item for group members that don't already exist...
Okay, sounds like you could use a simplified version of Pieters method:
To get an array of all records that exist in both tables:
Use intersection(variables('BigArray'),variables('SmallArray')) and store it in a variable, lets call it CommonRecords
Then use a filter array action, where you filter the big array, and as the filter condition use:
contains(variables('CommonRecords'),item()) is equal to false
The output of this will be an array which holds all the records from the big array which are not present in the small array
@KvB1 Hi 🙂
I need to know which one is missing so that I can assign the right status to it. When we delete a booking for a person, we need that person to get the status available. When you delete a row in Dataverse only the id of that row is saved, none of the field values or related values are saved. This is a workaround to assign the right status "booked" or available" for candidates going an onboarding training.
Good to know is that Candidates is listed in one table, Bookings in one table and Course slots in one table. Booking table is having a lookup to each of the other two.
Whats the goal of comparing them? You want to know which items are in array 1 but not in array 2?
@abm that's a good idea. These are the id string for dataverse tables so they are like this: "3714c30a-fd65-4a42-8b3e-4fd2c664dbb6"
It might work with parse json on both arrays, comparing the body and contains with the current item. Going to try...
Hi @shavora
Could you please post a screenshot of your flow? Just a quick thought is convert both sides of the values to string() as well.
Thanks