function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
NYNickNYNick 

Preventing a duplicate contact/lead

Hi,

Can anyone assist me or guide me in the right direction?

 

Currently there are some members in my organization who forget to do a quick search for a lead or contact before creating a new contact.  Is it possible to create a rule or formula which will not allow a user to be created if the email is already in the system?

 

Greatly appreciate any feedback.

 

Nick

Ispita_NavatarIspita_Navatar

One quick way of doing it is to make the email field unique, but if you are using the standard field then may be you cannot change the characteristic of your field that is to make it unique, then you can do 2 things:-

1. Create a custom email field and make it of type unique

2. In acse you want to use the standard ones then you can write a small trigger on the lead and contact and on insert and update event check if the email provided exists in the system or not , if it does raise an error else continue.

 

Did this answer your question? If not, let me know what didn't work, or if so, please mark it solved.

 

 

 

NYNickNYNick

No, I dont think this helps.  By making it unique, we would still need everyone usung SF to check if the contact exists.  I am experiencing difficulty with poeple checking before adding. 

I also have another dilemna that relates to this.  From our website, when a customer purchases an item they are automatically added to our SF, so we might have duplicates come in through the website, which is ok, but if I set a rule to not allow duplications then the system will kick back to the customer.

Ispita_NavatarIspita_Navatar

I think your issue can be resolved by implementing a trigger on contact/lead which checks on before insert event whether  such a lead/contact exists it can just be updated.

tanakstanaks

Hi there Ispita,

 

Could you just clarify how you set triggers up? Our problem is that we don't want an identical contact being inserted under the same account. The same email address can however exist on different records.

 

Please advise.

 

T