Issue symptoms
A known limitation of the Salesforce integration is that an update to a mapped formula field in either an account, a contact, or a lead will not trigger a synchronization to Zendesk. This is a problem if you use a formula field to sync the values of Salesforce lookup fields as described in this article:Salesforce: Syncing lookup field information to Zendesk Support. This sync issue is caused by a limitation in the Salesforce Streaming Events API, where changes to formula fields do not lead to the creation of a streaming event.
The solution to this problem is to create an automated process (aka "Flow") in Salesforce using a new hidden field that is automatically updated whenever one of your key Salesforce fields change.
Resolution steps
There are three parts to this solution. First, create a new checkbox field in Salesforce to be used as a hidden sync trigger. Then, create a corresponding checkbox field in Zendesk and add it to the sync mapping. Finally, create a flow using the Salesforce Flow Builder to automatically update the new checkbox field.
来create the new field in Salesforce
- Go to theObject Managerand select the object type you want to sync.
- Go toFields & Relationshipsand add a new field.
- ChooseCheckboxfor the data type and give it a name, for example,Formula Fields Updated?. Leave the default optionunchecked.
- Select the appropriate field-level security, making sure that system administrators have access to the field.
- On the page layouts settings page, uncheck all options. This field is only used in a background process and shouldn't be on the page for users to update.
来create the corresponding field in Zendesk and update the mapping
- Open theUser fieldspage or the组织领域page, depending on whether you sync to organizations or users.
- Add a new checkbox field. Name the field something that indicates that it's only used for Salesforce sync purposes, for example,Salesforce internal use only.
- Add the new field to the Salesforce mapping. Follow the instructions in this section:Configuring Salesforce Contacts or Leads to Zendesk users sync.
- In the mapping section, add a new mapping for the new Salesforce checkbox to the new Zendesk checkbox and save the configuration.
来create a Flow in Salesforce
- Go toSetup>Platform Tools>Process Automation>Flowsand selectNew.
- Choose the "Record-triggered flow":
- Select an object whose field-changes will trigger this flow (Account/Contact/Lead) and specify that you want this flow to run when a record isupdated:
- Add newORconditions for each relevant field
This will not be the formula field itself, but rather the field on which the formula field is based.
For instance, if you have a formula field calledAccount Manager Namethat'smapped in Admin Center, the flow should respond to changes to theAccount Managerfield (the lookup field on which the formula is based):
For each field you'll include the field on the left, the Operator "Is changed" and the value of "True" - When you are done adding conditions, choose to "Optimize the flow for Actions and Related Records":
and click "Done" - Within the Flow Builder itself, click on the "+" to add a new element":
- Choose "Update triggering record"
- Create an action that checks the Checkbox field created earlier in this guide:
- Repeat steps 7 & 8 but this time create an action that UN-checks that box:
- Your finished flow should look like this:
- 保存并激活流。
Go ahead and update one of your lookup fields in Salesforce and see if the account or contact or lead syncs over to Zendesk as you expect.
2 Comments
Thank you, this is a helpful workaround!
Would this also work for a Picklist that is not updating in Zendesk?
Pleasesign into leave a comment.