Duplicate management in Winter 15

  • 4
  • Question
  • Updated 2 years ago
  • Answered
How can we allow users to quickly enter leads and contacts through Skuid tables but still take advantage of the duplicate management feature that's GA in Winter 15?
Photo of Joe Ort

Joe Ort

  • 2,266 Points 2k badge 2x thumb

Posted 5 years ago

  • 4
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,828 Points 20k badge 2x thumb
Joe.  We are looking at that capabilty in our production CRM.  However in Winter 15 it is just in Beta - When Spring gets installed in our Org (two weeks from now) I'll take a deep look and report back.  

Ok? 
Photo of Chandra V

Chandra V, Champion

  • 7,650 Points 5k badge 2x thumb
We were part of the Dupe pilot that is now GA - was wondering how to expose the message the user when a duplicate rule has been violated.  It seems our skuid pages just churn and have to be killed off when it does happen and the user has no idea why.
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,828 Points 20k badge 2x thumb
Chandra,  we have not yet been able to look into what it would take to support the Dupe Blocking feature that is now GA.  Know for sure that it is on our roadmap. Let me do some digging today and get back to you.  
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,828 Points 20k badge 2x thumb
Another question comes to mind.  When the page churns,  do you get a javascript error in the browser console?    Can you send it to us? 
Photo of Chandra V

Chandra V, Champion

  • 7,650 Points 5k badge 2x thumb
I went looking for an error message on the Chrome console and didn't see one.  It appears to be giving the user a message (on the SF native page) with an user input - to continue or to stop.
Photo of Pat Vachon

Pat Vachon, Champion

  • 44,426 Points 20k badge 2x thumb
Any progress on this. A client is asking about Duplicate Management on Accounts.
Photo of Will Soupcoff

Will Soupcoff

  • 734 Points 500 badge 2x thumb
Ditto.  Currently blocked from implementing duplicate management.
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,828 Points 20k badge 2x thumb
Official Response
Ok here is a field report.   Duplicate Management and Skuid - the current situation. 

I implemented Duplicate Management in a Dev Org. 

I turned on a Matching Rule that fired if a record's email matched that of another record. 
Then I started playing with a series of combinations of Duplicate Rules to see what the impact was on the skuid pages.

 


1. When the Action option is "Block" for Create or Edit, the "Alert Text" gets posted at the top of the page where you are trying to save, and the user is prevented from saving. 




2. When the Action is Allow and only the report operation is triggered, the page successfully saves and the duplicate record set entry is created

3. When the Action is Allow the alert operation is triggered - there is no alert shown.  The user is just taken to the Lead Detail page. 


So two out of three.. Not bad,  but we can do better. 


The other aspect to duplicate management is the duplicate record set - a group of records that are all duplicate one to another. This allows reporting and custom fields etc.  Skuid cannot currently connect to the duplicate record set in a model because of the API level we are currently using.  We will be fixing this API level in our next release and this will allow more complete reporting on duplicate records.  I believe this will also allow us to successfully replicate option 3.

Stay tuned for continued improvements.  We'd love to hear any of you who are being successful with duplicate management as it currently is possible with Skuid. 
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,828 Points 20k badge 2x thumb
Updated field report.  

With a recent skuid update (6.8.20) you can build a model on the object that Salesforce writes to when the "report" function is used in duplicate management.  (DuplicateRecordSet and DuplicateRecordItem)  This allows you to implement a form of the "Alert" method that is available using Duplicate Management.

For this to work correctly the Duplicate Rule detail should be set to "Allow" duplicates to be created (or edited),  and for the "Report" operation to be effected on Create.

 

Note:  The "Alert" operation should not be selected,  as in Skuid, the alert message prevents you from being able to save the record.

Now that we have the duplicate reported,  we can add some features to our "lead detail" page that alert the user to the presence of duplicates.   
Create two new models on the "DuplicateRecordItem" object.  
- One should return the recordSet value for any rows where the recordID = the Lead Model Id.  
- A second should return all recordID's where the recordSet is equal to the item returned in step 1.  It should also exclude the recordId that is equal to the Lead Model Id. 

Now you can use the second model in a table to show possible duplicate values, and use conditional rendering to post a big red ugly message when possible duplicates have been detected. 




This makes sense in a scenario where the initial new lead page is very thin.  The user only has to enter the required fields.  Then when the record is saved and the dupe check is effected, the user either selects the matching lead and deletes the record they started or fills out the remaining detail on the edit detail page. 

It also seems to be that the DuplicateRecordItems take a bit of time to be created.  In your new lead page - you may want to introduce a second or two of delay in the save process.  Do this by making the save button be an action sequence that saves the lead,  waits a second,  then executes the URL redirect. 


CODE ALERT!  I've saved the sample code I created above to Github.  You can create a new page in your org and paste in the XML.  Here is the link. 
Photo of Gary

Gary

  • 1,558 Points 1k badge 2x thumb
Hi Rob, were there any updates or changes to these features in releases after 6.8.20?
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,828 Points 20k badge 2x thumb
Gary.  There have been no changes to this scenario as far as I know. 
Photo of Mansour

Mansour

  • 2,218 Points 2k badge 2x thumb
Hi,
Is the duplicate record set now available for access?
Would love to know if any progress has been made on this.
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,828 Points 20k badge 2x thumb
The Duplicate Record Set and Duplicate Record Item objects have been accessible by Skuid models since mid 2015.