Looking for PowerObjects? Don’t worry, you’re in the right place! We’ve been part of HCL for several years, and we’ve now taken the final step in our acquisition journey: moving our website to the HCL domain. Nothing else is changing – we are still fanatically focused on Microsoft Business Applications!

PowerObjects Blog 

for Microsoft Business Applications


Microsoft Dynamics CRM Data Import – Setting the Primary Contact Field #1

Post Author: Joe D365 |

In Microsoft Dynamics CRM 2011, the out of the box import tools have been greatly improved. We recently worked with a client to import their Accounts and Contacts from a spreadsheet. Best practice is to import your Accounts first, then import your Contacts. The reason behind this is to allow the import process to associate the Contact to the Account. But while reviewing the data the client noticed that the primary contact field was not populated on the Account form. Since the contacts don't exist yet, there was no way to populate this field while importing the Accounts. Below is a simple way to work around this issue for setting the primary contact field.

First create a new field in the contact entity, in my case I called it Primary Contact and set the field attribute to Two Options. You do not need to add this field to form, it simply needs to be available to update during the import.

After the field is created, create a new workflow that will use this new field to trigger the workflow. Make sure the workflow is set to be triggered when a "record is created".

The first step is to add a check condition to make sure the primary contact field equals "Yes"

CRM 2011 - setting the primary contact field

If that value equal yes, then the workflow will update the Parent Customer field in the Account entity. You can do this by selecting the contact has the Primary Contact field.

Microsoft Dynamics CRM Blog

The last step is to add a new column to your contact data spreadsheet. You can call this column "Primary Contact" and then you will need to set a value for each row.

Now when contacts are imported, the workflow will trigger and update the primary contact on the Account entity.

If you liked this, check out setting the primary contact field part 2!

Happy CRM'ing!

Joe CRM
By Joe D365
Joe D365 is a Microsoft Dynamics 365 superhero who runs on pure Dynamics adrenaline. As the face of PowerObjects, Joe D365’s mission is to reveal innovative ways to use Dynamics 365 and bring the application to more businesses and organizations around the world.

5 comments on “Microsoft Dynamics CRM Data Import – Setting the Primary Contact Field #1”

  1. Not the best way to do it..
    You should research the zip functionality of the default import tool instead.. It does exactly what you are doibg in a workflow.. Just alot smarter..

  2. Rune,

    You are correct that you can now relate contacts and account via the import tool but the issue still exists if you have multiple contacts related to an account. But, in my example I have 5 contacts for one account. The import tool does not have a way to state which ones is the primary contact. So it pulls the first contact from the list and sets that as the primary contact. That will not work for my customer…. Also there is a ton of data manipulation you must do prior to getting the data to import in correctly.

    Hope this clarifies things.

    JoeCRM

  3. Hi, Is there a way of doing this in reverse - so if the contact already exists can I set up a workflow to assign that contact as the primary on my new accounts I wish to import? I am working CRM2013 for reference.

    1. Hi Gavin - Yep - this is doable in reverse but not out of the box. We would need a plugin to do this.

  4. Joe,

    When I go to step "Update Parent Customer field I got stuck. I don't know where to set this.
    I couldn't even find the field Parent Customer in Account Entity, but when I try to map the Source field to CRM field, Parent Customer shown in mapped field.

    Can you help me to figure it out?

    Thanks.

PowerObjects Recommends