I have designed a functionality to override the Lead Conversion standard functionality. The functionality works as follows :
There is one custom setting which contains information of Lead field Mapping with Account fields during Lead Conversion.
There is a scenario where I am providing the users to Update Existing Account, rather than creating new ones while converting the Lead.
So that whenever I have a Lead whose Company Name already the name of an Existing Account, and I go on to convert the Lead , then the New Account will not be created, rather the existing Account's information will be updated.
lc = new Database.LeadConvert();
lc.setLeadId(objLead.id);
if(updateexitaccount)
{
if(accmap1.get(comp) != null)
lc.setaccountid(accmap1.get(comp).id);
else if(accmap2.get(website) != null)
lc.setaccountid(accmap2.get(website).id);
}
lc.setOverwriteLeadSource(true);
objLeadConvertResult = Database.convertLead(lc);
However, when I am doing the same, I observed that the Account is not updating the standard field values like that of Industry, Lead Source, Phone Number, etc. On the other hand, it is updating the values for custom fields perfectly. Is there any workaround for this issue?