SOLVED

Unknown cause of lead merge (leaddb) - Expert knowledge required!

Go to solution
Veronica_Holme4
Level 10 - Champion Alumni

Re: Unknown cause of lead merge (leaddb) - Expert knowledge required!

Since this isn't the batch conversion issue and Justin has correctly identified (I've seen that one too) I feel like we are back to perhaps a non-standard conversion process in Salesforce we need to identify. If Marketo can't see the lead through it's conversion to a contact (even for a little while) it will believe it needs to create a new record, which turns out to be a duplicate. I've worked with literally hundreds of synced instances, and every time I have seen this issue it has turned out to be a non-standard conversion process, a permissions issue with the Marketo sync user, or something else that means Marketo loses track of the original lead on conversion. The fix is always in Salesforce. We just need to nail it down.

Sean_Richards
Level 5

Re: Unknown cause of lead merge (leaddb) - Expert knowledge required!

OK, I'll play that game

My Sync user is a custom profile cloned from the system admin profile in SF. It has basically full access to the SF org, bar some objects that are not relevant to it.

Is there anything specific to audit on this user? It certainly has never displayed a permission issue to date.

If it was not a permission issue, when you say "non-standard conversion process", what does that mean?

When you say "something else that means Marketo loses track of the original lead on conversion", what could cause this?

Thanks Veronica!

Sean Richards
Matt_Reilly1
Level 2

Re: Unknown cause of lead merge (leaddb) - Expert knowledge required!

Sean, were you able to find the solution to this? I'm seeing the same leaddb issues happening on my end. We're using Leandata to run our conversion, but are transitioning to Ringlead soon. I thought Ringlead would be the fix, but am distressed that you're having issues with Ringlead conversions as well. 

Sean_Richards
Level 5

Re: Unknown cause of lead merge (leaddb) - Expert knowledge required!

Hi Matt,

I've been holding off bothering to reply to this thread. Yes, I found a solution. After my ticket spent months in Marketo's top tier support channels, they didn't have a solution. Well, not entirely true. They did, but it was not the actual solution. Here was there response.

-----------------------------------------------------

Hi Sean, 

Thank you for your patience with this one. Our Engineering team looked into this case and found logs for the affected records. One such is below: 

Logs show operations of data pull: 
Lead Pull conversion SOQL: 
Mar 28 17:42:31 

Contact Record created in sfdc at: 
sfdc_created_date: 2019-03-28 17:42:32 

Contact pull-updates SOQL: 
Mar 28 17:42:46 

During a Lead to Contact conversion. When the standard conversion process is performed in SFDC, a new contact is created in SFDC and the data mapped between lead and contact is used to populate the fields of the contact in SFDC. The lead in turn becomes a "shell" of a lead. This conversion is pulled during the Pull Conversion operation in the sync. New contact records or contact updates are both pulled in the Contact Pull-Updates operation in the sync. 

The lead was converted to a contact during the short window of time between the conversions were pulled and the start of the updates being pulled. The new contact was pulled over to Marketo by the pull-updates operation rather than the pull-conversions. Hence the creation of the new contact in Marketo - a duplicate. During the coming sync cycle after that, the pull-conversions operation merged the duplicates to complete the conversion. 

Our engineers have confirmed that when this scenario occurs (a conversion happened in that small time gap), this behavior is expected to occur. 

-----------------------------------------------------

See, I already knew this. That the API calls run in a specific order (there is a post on this somewhere) and that these got out of sync. But why? There is no answer to that, nor why my records caused this to occur dozens of times.

Well. I can now report that in our case, this was not due to RingLead. It was actually caused through the combination of having a lead validation rule in SF, plus a small setting enabled in SF.

In SF, navigate to Setup then search for "Lead Settings". Locate the "Require Validation for Converted Leads" checkbox and Disable this setting. This setting was causing field validation and workflows to execute on conversion, and this was the cause for breaking the sync API execution timing.


Prior to figuring this out, we also setup a great Marketo program that "captured" these irregular merge records. I highly recommend creating this as an operational program so that you stamp these errors as they occur so that you can clean them up.

Basically, the activity log registers two "Person is Created" records when this bug occurs. So you can capture that and add the record to a static list. My list currently has 18 people in it.

irregular-merge-1.png

irregular-merge-2.png

irregular-merge-3.png

I wanted to let support try and come up with this solution or at least tell us to check that setting in SF, but unfortunately they didn't have many cases of this error occurring and never once pointed to this SF setting as a possible cause of the issue. 

I feel pretty confident that if you disable that setting in SF, you two will see these issues cease to occur. 

Funny thing that having that program to stamp them in place, one person (like 1 week ago) triggered the issue to reoccur. But I guess that's acceptable and is what you would consider "regular" occurrence of this de-sync timing issue.

I hope that this information helps others now and in the future. I lost maybe 40 hours to this issue.

Finally, shout out to Veronica Holmes‌, it was an issue in Salesforce  Nice work haha.

Cheers,

Sean

Sean Richards
Matt_Reilly1
Level 2

Re: Unknown cause of lead merge (leaddb) - Expert knowledge required!

Sean, 

This is amazing! Thanks for sharing. How did you figure out that the "Require Validation for Converted Leads" setting had to be disabled to fix the issue?

Sean_Richards
Level 5

Re: Unknown cause of lead merge (leaddb) - Expert knowledge required!

I think I just spent a lot of time testing different things. Veronica kept pointing out that it must be a "non standard conversion", but I had no specific Apex or Workflows hooked on to conversions. But when I found this setting which related specifically to conversion and what is executed on it, I just tested disabling it and found it to solve the issue.

The big question is though..... Did this solution work for you?

Sean Richards
Pamela_Hudadof2
Level 2

Re: Unknown cause of lead merge (leaddb) - Expert knowledge required!

Hi Sean (and others who read this),

      I have read all of the related nation posts that I can on this.   The fact is that this issue is occurring on most of my client's Marketo instances.   It doesn't matter whether the SFDC instance has the Lead Setting set or not.   It still happens.  It doesn't matter whether there is a bulk of records being converted or one.   It still happens.

     What is really, really bad about this is that the duplicate Contact and merge are causing data loss in our systems.   I first discovered this as I watched GDPR audit history get erased on the merge.   It got erased because when the duplicate Contact was created, Marketo logic saw it as just another new Contact from SFDC and tagged and processed it as it would any other record.   Then I started looking further.  Pretty much any new Contact processing (field data) you have in Marketo is likely to cause original data from the Lead to be lost when the Contact is merged.   This is simply unacceptable.

      I have gotten to the point where I am now identifying when these duplicates happen and repressing as much of the Marketo processing as I can on the duplicate Contact so that I don't lose data on the merge.   But it gets worse.  Say you have custom object records on your original Lead.   Since it will always be the losing record on the SFDC lead conversion merge, those custom object records get lost.   There isn't anything I can think of to fix that.   

     And quite frankly, the whole repression solution I've worked up can be a really difficult solution to implement if you haven't been fastidious about centralizing most of what you do in Marketo.   

      I am going to give a try to see if Marketo support will start to see how large an issue this is now and finally find a way to fix this for all of us.

 

      Thanks to all that have worked so hard to get insight, find work-arounds, document their journey with this issue here.

 

Best,

Pam Hudadoff

 

    

kascampbell
Level 1

Re: Unknown cause of lead merge (leaddb) - Expert knowledge required!

@Pamela_Hudadof2 I have been working with the Marketo Product team on this for the last year almost on this issue. I believe a fix for this went out on the 14th across all Marketo instances. I have been eager to see if this issue persists for any other customers. I have seen this issue fixed in our instance of Marketo. Let me know if you see any changes on your side! 

Jay_Jiang
Level 10

Re: Unknown cause of lead merge (leaddb) - Expert knowledge required!

Quite possibly Marketo changed the default reasons at one point in time. But yes, some in deep dive documentation into lead merge would have been nice.

Sean_Richards
Level 5

Re: Unknown cause of lead merge (leaddb) - Expert knowledge required!

There is more information Justin Norris added here, which also confirms the issue: https://nation.marketo.com/message/200295-re-converting-lead-to-a-contact#comment-200295

Disabling the sync is not a solution however, as I tested the conversion being done from RingLead in batch, Ringlead, single records one by one, and Manual conversion within SF and was able to trigger the issue in all three scenarios.

Sean Richards