Hi,
We need to update leads and sets it parent contact when contact emails match. We are importing approx 500 leads per days using C# using service proxy.
We also import new or changed contacts from in-house system. We use contact email as a unique. We have a custom field on lead that ensures we dont import duplicates.
Would be recommend best practice to connect the leads and contacts in bulk.
We found that importing leads (800,000+) is very time consuming using OrganizationServiceContext. It is very slow, as we have to check if the lead already exists prior to insert. Adding additional logic to check for contact or account slows down the process even further.
Ideally I would like to run a query as follows (psudo code)
update lead set lead_parent_contact = contactId
from contact where lead.email = contact.email
Any help would be greatly appreciated