Hi,
I have a Flow that gets triggered when a SalesForce record is modified and then updates the same record in a SharePoint list.
The Flow works by getting all the list items (SharePoint - Get Items) and matching the list record number with the record number of the modified SalesForce record. The flow works fine but takes 1h to run.
I have 7000 unique items in the SharePoint list and I would like the flow to stop after it has found the one item that needs to updated. Right now I have initialized a variable to 0 which gets set to 1 when the list item is updated - when the variable is 0 the flow stops doing anything but it still has to go through the rest of the list items. I tried putting the Apply to Each inside a Do Until but it didn't work: the do until only "looped through" one instance since the Get Items returns one instance - or so it seemed.
Is there any way to terminate the Flow inside the Apply to Each... control terminate isn't allowed inside an Apply to Each 😞
Heres a picture of the flow:

Regards,
T