is there a good reference for new users for best practices and stuff like that?
in pretty quick time just screwing around with it I have a working prototype recipe between Epicor and SFDC that will Update and create new SKUs in SFDC when the Epicor SKU is changed which is cool. but I noticed that even if nothing changed by the recipe the last Modified date is updated.
if I’m checking a handful of Fields Such as Description, PLM State, Product Line etc. do I have to test each one and see if something is changed before updating or is there a trick to this?
SFDC is smart enough to know that nothing changed as far as the history so for example PLM state doesn’t show changed from GA to GA but I don’t want users to see that last modified date and go looking for what was changed.
This is more of a Salesforce question than an Automation Studio one. If you pass an Update or Upsert into Salesforce, all of the records are going to have their LastModifiedDate updated, even if no fields actually changed. To replicate this or prove this out in the Salesforce UI, if you go to a record page and click “Edit” but make no changes and then hit “Save”, it updates the Last Modified Date. As a side note, this will also cause any flows and triggers to run.
If you don’t want this behavior, you would likely need a lookup and a condition in the recipe to only pass the update to records where the new value varies from the existing value. In our use case, we decided to live with the Last Modified Date updating because adding those sorts of conditions make batching harder/impossible.
Alternatively, you could use a UD checkbox on the Epicor Part table and a data directive to set that checkbox to true when certain fields are changed from any to another. Then you could have a condition on the Automation Studio recipe to only process records where that checkbox is true (you’d need to set it back to false in the recipe after the update to SFDC). This adds some complexity and requires data directive in addition to the AS recipe in order to work, but would potentially allow you to get the desired results and still have the option to use batching without consuming a bunch of extra Workato tasks.
There is some useful info on the Workato site if you haven’t dug around there yet. Also just looking at the community recipes yields ideas. I asked Epicor if they were planning to enable kinetic users to share recipes with eachother, since kinetic isn’t a public connector we can’t share on Workato’s site. They said they were thinking about it.
thanks… its interesting that Field history is smart enough to know that the filed didn’t change but last modified isn’t but I guess it could be a feature so you know that the automation touched that record
but what I did was created a field called PLM last modified and if any user important fields are changed this field is updated by an SFDC Flow…
does there happen to be an ischanged() function in workato? in SFDC flow I can add a condition when Unit price ISCHANGED which could be helpful here or would you have to pull each field from SFDC and test it?