Microsoft Dynamics CRM provides some useful tools for importing your data, such as templates, the Import Data Wizard, and data maps. These features are designed to make the import process as pain free as possible. However, we at xRM (www.xrm.com) know that complications and errors can still arise, and it can be frustrating if you aren’t able to locate the source of the problem. In this post, let’s examine two of these common errors, how we find them, and how we resolve them.
First, let’s take a look at the data that we want to import. It’s in a .csv file we created in Excel:
This is a simple list of Contact records we want to bring into our CRM database. It has just five attributes: First Name, Last Name, Title, Business, and Business Phone. Let’s proceed with the import and see what happens. One way of doing this data is by navigating to Settings> DataManagement, and then clicking Imports. Next, click the Import Data button in the command bar and proceed through the ImportData Wizard that appears.
Now, it is time to map the fields. As you can see above, I’ve mapped the “Business” column to the Company Name field of the related Account record. Let’s finish the import and then examine the results.
Why did we have five errors and zero successes? Rather than trying to import the same document again as is and running into the same problem, let’s first locate the issue. To do this, we can open the record of the import itself. In this example, we can click “Client List.csv.” When the record window opens, click the Failures label in the Related pane on the left of the form.
In the Import Log, we can see a description of why each record was unsuccessfully imported. The first four records could not be brought in because a lookup reference could not be resolved. This is a common mistake new users to Dynamics CRM encounter when bringing in new contact records: trying to import new records from two different entities in a single file.
The Excel document shown above represents both Accounts and Contacts. The “Business” column references the Account records. If those records do not already exist when bringing in the related Contact records, the lookup reference error occurs. To avoid this error, we can copy and paste the Business column into another Excel file, along with any other data relevant to the Account records. We then import the Accounts before we import the Contacts. This time, the lookup reference error won’t trigger because there will be existing Account records with which the Contacts can be related.
What about the duplicate error for the last record? In the ImportLogAssociated View there is a column called “Original Row Number.” This helps us locate the exact record in the spreadsheet that is causing the error. In this example, it’s row 6, “Becky Miller.” Let’s say we know for a fact that Becky does not already exist in our database. So how could a duplicate have been detected? To find the answer, let’s navigate to Settings> DataManagement > Duplicate Detection Rules.
In a nutshell, a Duplicate Detection Rule in Dynamics CRM helps maintain the integrity of our data. When records are imported or created, the system will use any published rule to verify that the incoming record does not already exist. An example of such a rule is “Contacts with the same first and last name.” By default, Dynamics CRM comes with nine published Duplicate Detection Rules. Any of them can be deactivated and new ones can be created. Let’s take a look at the published rules for Contact records.
We know Becky does not have the same first and last name as anyone in our system. We also know that we’re not importing email addresses in this import, so that rule couldn’t have triggered the error. So that leaves “Contacts with the same business phone number” as the only rule preventing the successful import of Becky’s record. This is actually a common misstep in imports. What happens is users attempt to import a group of contact records that work for the same company. Oftentimes, the business phone number will be the same for all of the contacts because it is the company phone number, not a direct line. This triggers the Duplicate Detection Rule and prevents all but one of the Contact records from being created. Becky already has a coworker in the system with the same business phone listing. Therefore, the system sees this as a duplicate record.
To prevent this from happening, we can simply select the rule, and then click the Unpublish button. We’ll then be able to import Becky’s record successfully. We can even Publish the rule again once the import is complete.
The lookup reference and duplicate detection errors are common in data imports, but they certainly aren’t the only problems that can occur. Be sure to check the record of import in CRM, especially the listed failures to locate the source of the problem and hopefully find a solution with as little headache as possible.
If you would like to learn more tips, tricks, and tutorials such as this one, please check out our xRM blog and our Success Portal. If you would like to receive training from our team of experts, please inquire about our QuickStart Training.