Denote Duplicate Records when Users Create them Manually

In this blog post, we explore the options to identify the duplicate record created when users are presented with the duplicate management warning message.

Full credit goes out to Tom Hoffman (https://success.salesforce.com/ProfileView?u=0053000000BgRsl) over at Accidental Admins (https://twitter.com/AccidentalAdmin) for the solution. I originally was sparked to write this post off of a Post I saw on the answers community – https://success.salesforce.com/answers?feedtype=RECENT&criteria=BESTANSWERS#!/feedtype=SINGLE_QUESTION_DETAIL&dc=All&criteria=BESTANSWERS&id=9063A000000E0OyQAK

I thought it was a neat solution so I wanted to explain it out step-by-step.

untitled

Business Requirement:

We definitely need to identify duplicate records created by users when they ignore the duplicate rule warning. Administrators need to know which is the duplicate record to merge them later as well as hone the duplicate management rules to improve duplicate rule performance.

Is there a way to stamp these records as DUPLICATE without apex?

untitled2

Suggested Solution:

Designing a Process Builder that updates a number field on the duplicated record once created as an indicator. Here is a walkthrough :

 

1 – Create the number field on the object, set the default value to 0.

untitled3

2 – Create a Process Builder on the DuplicateRecordItem object and evaluate when the record is created only.

4

3 – Set the Criteria; Choose the Condition field to be the Record ID from DuplicateRecordItem Object.

5

4 – Then, set the condition so that the Record ID starts with 003 (for contacts); check this link for ID prefix for each object.

6.png

5 – Add a field update for the field created in the first step; Let the value of the field be updated to “1”. Power of One – this will be helpful when you run a report especially if you want to know the number of duplicates in specific Accounts.

7

8

 

And… Now that you have read through this post completely here’s a small package you can install in your org if you don’t want to build the Process Builder and the Custom Field yourself. We have set this example up under Contacts as this is likely going to be the most common duplicate object we run into but the setup is the same for all objects.

Contact Duplication Identification: https://login.salesforce.com/packaging/installPackage.apexp?p0=04t1E000001AX9L&isdtp=p1