โ02-17-2023 07:46 AM
Hello,
Having an issue i can't figure out how to resolve the next escenario:
I have 2 Recipes updating the Customer Contact information, one form Salesforce and one from Epicor Kinetic but as there is not really a master record, by that i mean all changes can occur either on Salesforce or Epicor Kinetic, and both systems should have the same information, when either the Salesforce or Epicor Kinetic have changes, so when one run it trigger ana update on the other system, which trigger back the update to the first system and it get loop
Solved! Go to Solution.
โ02-20-2023 07:24 AM
If you can't go off the user and the "past X minutes" won't work, some other ideas to toss out there...
- Use a custom flag on the affected records like "just updated by sync". When Workato updates the target system it sets that to Yes, and then the triggered recipe checks for that. If it's Yes, it just updates it to No and exits out. Will consume 1 more Task, so that's a negative.
- I think the most robust, enterprise-level syncs like this would involve a 3rd system that serves as the "canonical" DB, but it might not be worthwhile if your needs aren't that strict.
โ02-17-2023 08:22 AM
There may be more elegant ways, but we had a similar situation and ended up examining the user_id that made the change and then ignored changes made by the Workato integration user_id. The idea being that we would only capture changes made by the users. Perhaps something like this could work for you?
โ02-20-2023 03:59 AM
@gjames Is correct. There is no out of the box way to handle this. Typically, you would have a designated API user, and thus exclude records updated by that user. In one scenario, I excluded record that has been updated in the past X minutes since I couldn't use the API user.
โ02-20-2023 07:24 AM
If you can't go off the user and the "past X minutes" won't work, some other ideas to toss out there...
- Use a custom flag on the affected records like "just updated by sync". When Workato updates the target system it sets that to Yes, and then the triggered recipe checks for that. If it's Yes, it just updates it to No and exits out. Will consume 1 more Task, so that's a negative.
- I think the most robust, enterprise-level syncs like this would involve a 3rd system that serves as the "canonical" DB, but it might not be worthwhile if your needs aren't that strict.