In Microsoft Dynamics CRM, you enable the duplicate detection feature, and then you create a custom entity.
You disable the duplicate detection feature, save the entity, and then publish the entity.
You export the customization for the entity.
You import the customization to a new system.
In this scenario, the import process is not completed, and you cannot import the customization. When this problem occurs, an error message that resembles the following is logged to the Microsoft Dynamics CRM Platform trace log file:
CrmSoapExtension detected non-CrmException - report will be sent to Watson: System.Web.Services.Protocols.SoapException: Server was unable to process request. ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.NullReferenceException: Object reference not set to an instance of an object. at Microsoft.Crm.Tools.ImportExportPublish.OneToManyEntityRelationshipProcessor.CreateNewEntityRelationship(XmlNode entityRelationshipNode, LocLabelHelper locLabelHelper, ExecutionContext context, MetadataHelper metadataHelper) at Microsoft.Crm.Tools.ImportExportPublish.ImportEntityRelationshipHandler.ImportItem() at Microsoft.Crm.Tools.ImportExportPublish.ImportHandler.Import() at Microsoft.Crm.Tools.ImportExportPublish.RootImportHandler.RunImport(String ImportEntities, String ImportRoles, String ImportWorkflows, ImportMask Mask) at Microsoft.Crm.Tools.ImportExportPublish.ImportXml.RunImport(String ImportEntities, String ImportRoles, String ImportWorkflows, ImportMask Mask) at Microsoft.Crm.Tools.ImportExportPublish.ImportXml.RunImport(String xml) at Microsoft.Crm.WebServices.ImportXmlService.ImportAll(String customizationXml, ExecutionContext context)
This problem occurs because duplicate detection relationships are created if you enable the duplicate detection feature when you create the entity. However, if you disable the duplicate detection feature when you export the customization, the exported customization does not contain these relationships.
This problem is fixed in the latest cumulative update rollup for Microsoft Dynamics CRM 4.0. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
949256 Microsoft Dynamics CRM 4.0 updates and hotfixes
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
For more information about software update terminology, click the following article number to view the article in the Microsoft Knowledge Base:
824684 Description of the standard terminology that is used to describe Microsoft software updates
For more information about Microsoft Business Solutions CRM software hotfix and update package terminology, click the following article number to view the article in the Microsoft Knowledge Base:
887283 Microsoft Business Solutions CRM software hotfix and update package naming standards