Scenarios are created for each object that will be deduped. The Scenario Details provide general information regarding the scenario, e.g. name, object type etc. and also specify how duplicates should be handled once detected. Different matching actions can be defined for inserts vs. updates. Duplicates to Accounts, Contacts, Leads as well as ANY other object can be detected and merged including custom objects. Cross object deduping is available for Lead to Contact and Lead to Account.
DupeBlocker Statistics are also tracked which report on the effectiveness of the scenario.
Users can have just one scenario per object or multiple. Having multiple scenarios allows for a multi-tier approach to duplicate checking typically with stricter scenarios blocking duplicates from being entered or auto-merging/converting the duplicates. Looser scenarios can be set up to allow the insert but report the duplicate in the form of a warning. Multiple scenarios also allow for different matching actions to be defined based on the types of records being inserted or the users that are doing the inserts using filters.
More information on filters can be found HERE.
If a record matches on multiple scenarios with different Match on Insert/Update Actions the order of operations is as follows:
Auto-Convert (Lead to Contact over Lead to Account)
- Auto-Merge
- Redirect to Existing / Redirect to VisualForce Page
- Do Not Insert / Update
- Custom Apex Code / Report Duplicate
If a record matches scenarios with both Custom Apex Code and Report Duplicate, then both will be done but Custom Apex Code will execute first. To prevent warnings from being created in this case, an API call can be made in the custom apex code to disable warning creation.
More information on the matching actions can be found HERE.
Creating a New Scenario
To create a scenario from scratch access the DupeBlocker Scenarios tab and click New.
DupeBlocker Scenario Details
Click on the help icon in Salesforce for additional information on each individual step.
1. Scenario Name
- Provide a text name for your scenario.
2. Scenario Type
- Select from the list of scenario types (Account, Contact, Lead, Lead to Contact, Lead to Account and enabled non-standard objects). Non-standard objects need to be enabled in the DupeBlocker Settings in order to show in the list.
- More information on enabling non-standard objects can be found HERE.
Lead to Contact and Lead to Account Scenarios will work in either direction, HOWEVER, by default blocking options ("Do Not Insert"/"Do Not Update" and "Redirect to Existing") ONLY trigger when a Lead is inserted/updated. Warnings are created in place of a block when a Contact or Account is inserted/updated that matches an existing Lead. Scenarios have an option, Block Account/Contact Matches, to allow blocking in both directions.
Auto-Convert ONLY triggers when a Lead is being inserted. Warnings will be created in place of a conversion when a Contact or Account is inserted/updated that matches an existing Lead.
3. Match on Insert/Update Action
Select how duplicates created via an insert/update should be handled.
Block messages, Bypass Block button and the ability to redirect to an existing record does not work on the Standard Salesforce Lightning Pages. In order for these options to work properly the standard pages will need to be overridden with DupeBlocker Lightning custom pages. Detailed step by step instructions on how to configure the overrides can be found in the Initial Configuration - Lightning page.
- Do Not Insert/Do Not Update: Blocks insert/update and provides a message to user that a duplicate was found with a redirect link to the matched record
- Blocking message in Salesforce Classic:
- Blocking message in Salesforce Lightning Experience:
- Custom override: Blocking message properly formatted, links to matched records, Bypass Block button shown in upper right. If "Redirect to Existing" is the action a pop-up will be shown alerting of the redirection, then the user will be redirected to the first matching record found.
- No Override, blocking message displayed on Standard Salesforce page
- Three additional options are available when one of these actions is selected
- Allow Block Bypassing: Provides the user with an option to bypass the block and insert/update the record
- Max Blocks Shown: Limits the number of duplicate records displayed
- Block Account/Contact Matches: Blocks Account/Contact inserts/updates when a matching Lead is found
- ONLY available for Lead to Contact or Lead to Account scenarios
- More information on these options can be found HERE
- Redirect to Existing: Will not allow the insert and automatically redirects to the matched record
- Available only for Match on Insert Action
- In Salesforce Classic, if multiple duplicates detected will display a list of all matches
- An additional option, Max Blocks Shown, is displayed when this action is selected
- Limits the number of duplicate records displayed
- Salesforce Lightning will display a redirect pop-up then auto redirect to the first match it detects, additional possible matches will not be shown
- Report Duplicate: Insert/update is allowed to complete but a warning is created
- Warnings should be reviewed on a regular basis
- If the records are confirmed as duplicates they can be merged from the warning
- If the records are NOT duplicates, the warning should be manually deleted
- More information on Warnings can be found HERE
- Warnings should be reviewed on a regular basis
- Do Nothing: No action taken
- Auto-Merge/Auto-Convert
- Available only for Match on Insert Action
- Auto-Merge: Ability to automatically merge duplicates as they are being entered
- Available for ANY single object scenario including non-standard objects
- Auto-Convert Lead: Ability to automatically convert a Lead to a matching Contact or Account during insert
- Available for Lead to Contact and Lead to Account scenarios only
- ONLY converts when a Lead is inserted
- When a Contact or Account is inserted a Warning will be created in place of the auto-conversion
- These options can be combined with Scenario filtering to auto-merge/convert records being entered via an external process that performs a single insert (e.g. Web to Lead inserts, filtering on Lead Source).
- An Auto-Merge or Convert Settings button will appear at the top of then screen when the scenario is saved
- Select to review the default settings and customize as needed
More information on Auto-Merge can be found HERE. More information on Auto-Convert can be found HERE.
- Redirect to VisualForce Page: Allows the user to define their own custom VisualForce page to display the duplicates however they choose
- Available only for Match on Insert Action
- This option is designed for advanced users with experience creating/customizing Visualforce pages.
- Custom Apex Code: Allows the user to define their own custom Apex Class to manipulate the duplicates however they choose
- This option is designed for advanced users with experience creating custom APEX Code.
4. Create Task for Warning
Warnings will be created for any inserts/updates flagged as "Report Duplicate". This option allows you to create warning tasks to notify either the "Current User", the "Scenario Owner", or both that a potential duplicate was identified. Tasks are set to trigger a task reminder in Salesforce but this can be disabled in DupeBlocker Settings.
More information on this setting can be found HERE.
- No: No tasks created
- Yes - Current User: Task created and the user performing the insert/update is notified of the potential duplicate
- Yes - Scenario Owner: Task created and the scenario owner is notified of the potential duplicate
- Yes - Current User and Scenario Owner: Task is created for both users.
Notes:
1. Salesforce does not allow creating Tasks for queues
- If the scenario owner is a queue the task will fail with an error
2. DupeBlocker does not have an option to email the tasks to the "Assigned to" user
- A custom trigger could be created, if desired, on the task object to generate the email
- The trigger would need to check for the creation of tasks where the subject starts with "Potential duplicate"
3. There is NOT an option to create a task for the owner of the existing record
5. Deployed
Check this box to deploy the scenario. Can leave the box unchecked for now and deploy when ready.
Note: Scenarios WILL NOT detect duplicates until the scenario is deployed and keys have been built for all existing records.
More information on building keys can be found HERE.
6. Bypass Security
If unchecked, Salesforce sharing rules will apply. Duplicates will only be detected for records users have read access to. Checked will identify duplicates regardless of the Salesforce sharing settings.
If "Bypass Security" is checked, but Salesforce sharing is implemented, it is recommended that warning tasks be assigned to the "Scenario Owner" as the user may not be able to merge potential duplicates based on their specific sharing rules.
7. Enable Dual Filters
If unchecked, any object filters will apply to both the incoming and existing records. When checked a separate set of filters, DupeBlocker Scenario Target Filters, will be added to the related list. This will allow separate filters for incoming vs. existing records.
More information on filters can be found HERE.
8. Person Account Scenario
Check this box if this is a Person Account or Lead to Person Account Scenario. Leave unchecked for Business Account or Lead to Business Account Scenarios. More information regarding customizing DupeBlocker to work with Person Accounts can be found HERE.
Special Blocking Actions
Ability to "Bypass" Duplicate Detection and Insert Duplicate
When the Match on Insert/Update Action is set to Do Not Insert/Update there is an option to bypass the block and insert the record. A warning will be generated by default in place of the block so that a DupeBlocker Administrator was aware that a duplicate was detected but the user chose to override the block. In DupeBlocker Settings there is an option, Block Bypass Creates Warnings, that can be unchecked if Warnings SHOULD NOT be created (the option is checked by default).
Note: The Bypass Block option will ONLY take effect if ALL BLOCKING SCENARIOS (Do Not Insert) for that object type have the bypass option selected. For example, if there are 2 Lead blocking scenarios, one matching on First and Last Name and email, and another matching on Last Name and Phone BOTH will need to have the bypass block option selected for the Bypass Block button to show in the blocking error message that is displayed to the user.
1. Select Do Not Insert for the Match on Insert Action
- Available for Do Not Update also
- NOT available for Redirect to Existing or any of the other actions
2. Check Allow Block Bypassing to enable this option
Classic:
Lightning (New/Edit pages overridden with DupeBlockerWrapper Lightning Component):
3. Users can now select Bypass Block to override the blocking message and insert the record
- A warning will be created when the duplicate record is inserted (will be optional when the production release is available)
- As noted above, the Bypass Block button will ONLY show if all blocking scenarios for that object type have bypass block enabled
Note: When selecting Bypass Block from a custom Visualforce page for inserting records a second "save" is required to bypass the block and save the record. When the blocking message appears click "Bypass Block" then the "save" button again.
Bypass Block DOES NOT work with inline editing.
Specify Maximum Number of Duplicates on a Block
When a scenario is set to Do Not Insert/Update, Redirect to Existing, Redirect to VisualForce Page, or Custom Apex Code there is an option, Max Blocks Shown, to specify the maximum number of duplicates to be listed.
- The option will ONLY show when those actions are selected
- For example, if there are 10 matches, but Max Blocks Shown is set to 5, then only the first 5 matches identified will be shown
- There is no way to specify which 5 will be shown
- For example, if there are 10 matches, but Max Blocks Shown is set to 5, then only the first 5 matches identified will be shown
- All duplicates will be shown if the option is left blank UP TO A MAXIMUM of 20
Option to Block When Accounts/Contacts Inserted
By default, ONLY Leads are blocked for Lead to Contact/Account scenarios set to Do Not Insert or Redirect to Existing. When checked will ALSO block new Contacts/Accounts when an existing Lead exists.
- ONLY shown for blocking actions in Lead to Contact and Lead to Account Scenarios
- Unchecked will ONLY block new Leads
- Warnings will be created in lieu of a block when a new Contact/Account is inserted (same behavior as DupeBlocker 2)
Additional Items/Fields
1. Buttons
- Edit: Select to edit the details of an existing scenario
- Delete: Select to delete and existing scenario
- All related items including rules, filters and and existing Warnings will be deleted when a scenario is deleted
- Note: Scenario Keys ARE NOT deleted until a "Rebuild All Keys" is run
- More information on keys can be found HERE
- Clone: Select to clone the scenario details
- Cloned scenarios are like new scenarios
- Marked as Rebuild Needed and the Last Key Rebuild date will be blanked out
- All DupeBlocker Statistics fields reset to 0
- Rule and Filters ARE NOT cloned also, just the details
- Cloned scenarios are like new scenarios
- Auto Merge/Convert Settings: Select to configure auto-merge/convert options
- This button is ONLY displayed when the insert action is set to auto-merge or auto-convert
- Rebuild Keys: Select to build matching keys JUST for this scenario
- Rebuild All Keys: Select to build matching keys for all deployed scenarios
2. Owner
- When a scenario is created the owner is the set to the user that created the scenario
- Owners can be updated at any time
- Scenarios can be owned by users or a queue
- If the owner is a queue DO NOT create warning tasks for the scenario owner as Salesforce does not allow assigning Tasks to a queue
- The Tasks will fail with the following error
*** Current User: DB Admin (dbadmin@xyz.com)
*** Org Info: XYZ, Inc. (00DE0000000dScmMAE)
*** Trigger: Lead after insert
*** Trigger.new size: 1
*** Trigger.old size: 0
*** isMerge value: false
*** Exception Type: CRMfusionDBR101.DB_Globals.UnknownException
*** Exception Cause: null
*** Exception Message: Unknown error in DB_Matcher.CheckWarningMatch() at check position 5.
Status Code: FIELD_INTEGRITY_EXCEPTION
Error Message: Assigned To ID: id value of incorrect type: 00GE0000001bR0IMAU
Triggering record Ids: 00QE000000PQdomMAD
3. Rebuild Needed: Indicates that something has changed in the scenario that requires the matching keys to be rebuilt
4. Last Key Rebuild: The date of the last successful key rebuild
5. Created by & Last Modified by
- Default Scenarios that ship with DupeBlocker will show "DupeBlocker" as the created by user, and the date the application was installed as the created date
- Custom Scenarios will have the user that created the scenarios and the date they were created
- Last Modified by will be updated any time a change is made to the Scenario Details OR the DupeBlocker Statistics are updated
Since updates to Statistics also cause the last modified information to be updated, It is recommended that Salesforce history tracking be turned on for key fields to track changes (e.g. Match on Insert/Update Action fields)