Setting up Out-of-the-box integration between Dynamics CRM 2016 and Dynamics NAV 2016!

What's new in Dynamics NAV 2016

Introduction

I have talked earlier about the new OOB integration between Dynamics CRM 2016 and Dynamics NAV 2016. But lets dig deeper into the theoretical setup of this integration and the surrounding architecture. I’ll end with a test case in which I’ll run through the entire setup.

Synchronizing Microsoft Dynamics NAV and Dynamics CRM

With Microsoft Dynamics CRM integration, you can decide whether to synchronize data between Microsoft Dynamics CRM and Microsoft Dynamics NAV. Synchronization is the process that makes the data in selected fields of Microsoft Dynamics NAV records (such as customers, contacts, and sales people) and the equivalent Microsoft Dynamics CRM records (such as accounts, contacts, and users) the same. Conceptually, synchronization copies data between Microsoft Dynamics CRM entities and Microsoft Dynamics NAV record types (tables). Depending on the record type, data can be synchronized from Microsoft Dynamics CRM to Microsoft Dynamics NAV and from Microsoft Dynamics NAV to Microsoft Dynamics CRM. As users work with data in Microsoft Dynamics CRM and Microsoft Dynamics NAV, synchronization keeps the data in both systems up-to-date.

Synchronization is accomplished using three main elements: integration table mappings, integration field mappings, and record couplings. For a description of these elements, see Integration Concepts and Terminology.

Before you can start to synchronize data, you must enable the synchronization setup, if not already enabled. For more information, see how How to: Enable Default Dynamics CRM Synchronization Setup. After synchronization is enabled, the next step is to couple Microsoft Dynamics NAV records to Microsoft Dynamics CRM records. Once records are coupled, their data can be synchronized. The synchronization process can be initiated manually and/or on a scheduled basis. The following table provides on overview of the ways you can synchronize records in Microsoft Dynamics NAV tables and records in Microsoft Dynamics CRM entities.

Type Method See
Manual synchronization Synchronize on a record basis.You can synchronize individual Microsoft Dynamics NAV records, such as a customer, with a corresponding Microsoft Dynamics CRM record, such as an account. This is typically how end-users will work with Microsoft Dynamics CRM data in the Microsoft Dynamics NAV client. For general instructions:How to: Couple and Synchronize Records Manually

For detailed end-user instructions:Working with Dynamics CRM Data in Microsoft Dynamics NAV

Synchronize on a table mapping basis.You can synchronize all records in a Microsoft Dynamics NAV table and Microsoft Dynamics CRM entity. How to: Synchronize Individual Table Mappings
Synchronize all table mappings.You can synchronize records in all Microsoft Dynamics NAV tables that are mapped to Microsoft Dynamics CRM entities. How to: Synchronize Dynamics CRM and Dynamics NAV Records for all Table Mappings
Full synchronization of all table mappings.You can synchronize all Microsoft Dynamics NAV tables and Microsoft Dynamics CRM entities that are mapped together, and create new records in the destination solution for uncoupled records in the source solution. You will typically run a full synchronization when you initially set up integration between Microsoft Dynamics NAV and Microsoft Dynamics CRM and only one of solutions contains data. A full synchronization can be useful in a demonstration environment. How to: Run a Full Synchronization
Scheduled synchronization Full synchronization of all table mappings.You can synchronize Microsoft Dynamics NAV with Microsoft Dynamics CRM on scheduled intervals by setting up jobs in the job queue. Scheduled Synchronization Using the Synchronization Job Queue Entries

Standard Microsoft Dynamics CRM Entity Mappings for Synchronization

The following table lists the Microsoft Dynamics NAV record types (tables) and corresponding Microsoft Dynamics CRM entities that can be synchronized out-of-the-box.

Microsoft Dynamics NAV Microsoft Dynamics CRM Synchronization Direction Default Filter
Salesperson/Purchaser User From Microsoft Dynamics CRM to Microsoft Dynamics NAV Microsoft Dynamics CRM contact filter: Status is No.
Customer Account From Microsoft Dynamics NAV to Microsoft Dynamics CRM and from Microsoft Dynamics CRM to Microsoft Dynamics NAV. Microsoft Dynamics CRM account filter: Relationship type is Customer and status is Active.
Contact Contact From Microsoft Dynamics NAV to Microsoft Dynamics CRM and from Microsoft Dynamics CRM to Microsoft Dynamics NAV. Microsoft Dynamics NAV contact filter: Type is Person and the contact is assigned to a company.Microsoft Dynamics CRM contact filter: Contact is assigned to a company and the parent customer type is Account.
Transaction Currency Currency From Microsoft Dynamics NAV to Microsoft Dynamics CRM.
Unit Group Unit of Measure From Microsoft Dynamics NAV to Microsoft Dynamics CRM.
Product Item From Microsoft Dynamics NAV to Microsoft Dynamics CRM.
Resource From Microsoft Dynamics NAV to Microsoft Dynamics CRM.

The Microsoft Dynamics CRM entities and Microsoft Dynamics NAV tables that are synchronized are defined by table mapping entries are defined in table 5335 Integration Table Mapping. You can view the mappings and set up filters from page 5335 Integration Table Mappings. The mapping between the fields in Microsoft Dynamics NAV records and the fields in Microsoft Dynamics CRM entities are defined by field mapping entries in the table 5336 Integration Field Mapping and additional mapping logic. For more information, see Integration Table Mappings and Integration Field Mappings.

Synchronization Rules

The following table describes rules that control the synchronization between Microsoft Dynamics CRM entities and Microsoft Dynamics NAV tables.

General Modifications to data in Microsoft Dynamics CRM that are performed by the Microsoft Dynamics CRM connection account are ignored. The changes will not be synchronized. Therefore, it is a recommended that you do not modify data by using the Microsoft Dynamics CRM connection account.
Customers Before a customer can be synchronized to an account, the salesperson that is assigned to customer must be coupled to a user in Microsoft Dynamics CRM. Therefore, when you are running the CUSTOMERS – Dynamics CRM synchronization job and you set it up to create new records, make sure that you synchronize salespeople with Microsoft Dynamics CRM users before you synchronize customers with Microsoft Dynamics CRM accounts.

The CUSTOMERS – Dynamics CRM synchronization job only synchronizes Microsoft Dynamics CRM accounts that have the relationship type Customer.

 Contacts Only contacts in Microsoft Dynamics CRM that are associated with an account will be created in Microsoft Dynamics NAV.
Currencies Currencies are coupled to transaction currencies in Microsoft Dynamics CRM based on ISO codes. Only currencies that have a standard ISO code will be coupled and synchronized with transaction currencies.
Unit of Measures Unit of measures are synchronized with unit groups in Microsoft Dynamics CRM. There can be only one unit of measure defined in the unit group.
Items When synchronizing items with Microsoft Dynamics CRM products, Microsoft Dynamics NAV automatically creates a price list in Microsoft Dynamics CRM. To avoid synchronization errors, you should not modify this price list manually.

Test Case

The end goal of this test case is to create a sales order in Dynamics CRM 2016, which will then be synchronized to and finally processed in Dynamics NAV 2016. Before we reach this scenario, we’ll first have to go some steps:

  1. Create a non-interactive user in Dynamics CRM
  2. Enter the correct credentials in the Microsoft CRM Connection Setup in NAV
  3. Couple CRM users to NAV Salespeople
  4. Couple CRM accounts to NAV customers
  5. Couple CRM Units Groups to NAV Unit of Measures
  6. Couple CRM products to NAV items
  7. Create a sales order in CRM

My setup for this test case: Dynamics CRM 2016 Online (V 8.0.1.79) and Dynamics NAV 2016 On Premises, hosted on Azure.

Lets start!

1. Create a non-interactive user in Dynamics CRM

Create a new user in Dynamics CRM 2016 and make this user a non-interactive user.

2. Enter the correct credentials in the Microsoft CRM Connection Setup in NAV

1.png

2

3. Couple CRM users to NAV Salespeople

Open NAV; go to Salespeople – navigate – user and pick a CRM to couple him/her to a NAV salesperson. As you can see, I won’t link this to the earlier created non-interactive CRM user.

3

4. Couple CRM accounts to NAV customers

Open NAV; go to the customer card and click on “navigate” in the ribbon. Next you can create a coupling between an existing CRM account and NAV customer or you can create a new account. You can also choose the synchronization after coupling:

  • Yes – Use the Dynamics NAV data
  • Yes – Use the Dynamics CRM data
  • No

4.png

After the coupling has been made, you can modify the account in CRM and it will be synced to NAV (depending on your “synchronization after coupling” of course).

5.png

Synchronize

Synchronization can be done manually or automatically through job queues. I’ll pick the manual option for this test case.

6

7

8

Result

9.png

5. Couple CRM Units Groups to NAV Unit of Measures

10.png

6. Couple CRM products to NAV items

11.png

7. Create a sales order in CRM and press “Submit”

12.png

The order status will then change to “submitted”, which will make it “read only”.

13

The order will then be available in Dynamics NAV.

14

Moreover you can create it in Dynamics NAV.

15.png

And that’s it for this test case! We had to jump through some hoops to be finally able to create sales orders in Dynamics NAV, but these steps (and couplings) need to be taken to create the initial setup. Afterwards you can start to gain the benefits of the entirely new Dynamics CRM 2016 – Dynamics NAV 2016 integration.

Source: Synchronizing Microsoft Dynamics NAV and Dynamics CRM and Integrating Microsoft Dynamics CRM in Microsoft Dynamics NAV

15 Comments

  1. Really nice guide. How do you deal with the synchronization of Payment Terms (paymenttermcode).
    Do you create a new entity for this in CRM – or do you map the paymenttermscode on the account and then manually change the other 3 paymenttermscodes on opportunity/quote/invoice?

    1. Hi Marianne,

      At this test case we have not synchronized any custom fields.

      But I’m working on a new post in which custom fields from CRM are synchronized and linked to NAV default fields. Furthermore, I’m looking into special cases as “payment terms” as the current documentation lacks detail.

      So at this stage I do not have an answer yet on your question.

  2. Flora

    This is very nice and helpful, thank you. Couple of questions though. Is this valid both for MS CRM 2016 On Premise & Online? Does this apply as well between MS CRM 2015 On Premise and NAV 2016? Thank you!!!

    1. Hi Flora,

      The documentation on Technet does not offer any clear solution on this one. So currently I can offer you only my experience. I have linked:
      – a CRM Online 2015 (Update 1) with a Dynamics NAV 2016 On Premises.
      – a CRM Online 2016 with a Dynamics NAV On Premises (On Azure).

      In the future I’m planning to link a Dynamics CRM 2016 On Premises with a Dynamics NAV 2016 On Premises.

      Personal note; When linking the CRM 2015 (Update 1) Online , I had some issues with syncing the sales orders. Issues I did not have with CRM 2016 Online

  3. I found a problem when I tried the test case. I created a quote from an existing opportunity which had a total amount of GBP 10720. When I created an order from the quote, however, the Total amount is reset to 0. Plus the order automatically was submitted for integration. What could have caused the issue or is it a bug in the integration process?

  4. Raúl

    I’ve followed this out ot the box sales order process integration that NAV 2016 offers. But, where should the partial quantities be shipped, in CRM or NAV?

  5. Nour

    Hello,
    When I map Items in NAV to products in CRM, how is CRM getting the pricelist? I am always getting in the pricelist item: Default NAV pricelist when I transfer Items to CRM. I want to change this default nav pricelist to something I want. How to do that?

    1. Koen vdv

      Hi Nour,

      you’ll need to change the default pricelist NAV is syncing with in Dynamics NAV.
      Under “Microsoft Dynamics CRM – Unit Groups”, you can change the coupling between the unit groups.

    1. Koen vdv

      Hi Nour, the error you receive is because the OOB connection will automatically create a new price list in CRM called “Default NAV Pricelist”. But you can change this to a pricelist which you already have in CRM.

  6. Pingback: Dynamics 365 breaks the OOB connection between Dynamics CRM 2016 and Dynamics NAV 2016 – Koen's CRM Blog

  7. Pingback: Top 3 Most Popular Posts of 2016 – Koen's CRM Blog

Leave a Reply

Your email address will not be published. Required fields are marked *