How to call workflow rule custom function before lead creation
Hi!
Brief explanation what we need to accomplish,
When new lead comes in zoho crm it should check whether email address entered for this lead is already existing in any other lead or not. If email address is existing already in the zoho crm lead it should update all fields data of existing lead with entered data of newly created lead that means while creating the new lead if it found duplicate entry for email field it should update the existing lead or else it should create new lead in zoho.
We have tried following two ways for this :
- Custom Button
- Workflow rule
We have implemented custom function in custom button and it is working fine there but there are some limitation of custom function implementation with custom button as below :
- As custom function can process maximum 10 fields of argument so it will update maximum 10 fields in case of duplication but in case of no - duplication we can not create new lead with all the entered field for lead using custom button because it will process maximum 10 fields so other fields won't be insert for that lead in zoho.
- As custom button will be on create lead page so, we can not remove the inbuilt "Save" button of zoho crm.
We have also implemented the same custom function inside workflow rule by using
instant action for
custom function we have created "Deduplication check" on Lead "Create" and condition is for "All records" but we are facing issues like when we are creating new lead with already existing email address it is not updating the existing lead and creating new lead and while we have checked in Audit log we have seen that workflow rule is triggering custom function after lead creation.
We are stuck here.
Do we have any workaround for this ?
Any help would be appreciated!