Integration Best Practices: Dynamics 365 CRM to Finance & Operations

Integrating Dynamics 365 CRM applications and Dynamics 365 Finance & Operations (F&O) via Dual-write provides bi-directional data synchronization. Users across applications benefit from seamless, real-time sharing of information about customers, vendors, people, products, and operations.

However, successfully implementing this integration requires system administrators and customizers to address some challenges and design constraints that are not obvious at first. Based on Encore’s experience completing such projects, this article outlines our recommended technical steps for integrating F&O together with Dynamics 365 CRM applications (like D365 Sales, Customer Service, and Field Service).

Table of Contents

  1. Familiarize Yourself with Integration Templates
  2. Explore Global Address Book
  3. Set Up and Configure in Both Environments
  4. Install Dual-write Apps
  5. Prepare for Form Customizations
  6. Review Business Rules
  7. Consider Temporarily Deactivating Dual-write Plugins
  8. Set Up Autonumbering
  9. Troubleshooting: Dual-Write Apps Not Syncing with Finance & Operations
  10. Additional Resources


A few notes before we begin.

  • The advice in this article is aimed mostly at the CRM side of the integration, because Microsoft’s public documentation for the needs of Finance & Operations administrators in this kind of project is already quite thorough.
  • Dynamics 365 Finance & Operations is now licensed as Dynamics 365 Finance and Supply Chain Management. However, most people still refer to it as “Finance & Operations” or “F&O.”
  • Dynamics 365 also now includes 5 different applications that serve different CRM needs, including Dynamics 365 Sales and Field Service. All of these applications use the same Dataverse structure, and the integration guidance below applies to all of them equally. You will also see this group of applications referred to as “Customer Engagement” or “CE” applications.
  • Dual-write is the name for the Microsoft integration technology that works between the Dynamics 365 CRM and F&O applications.
  • Before beginning the technical work of integration, your Dynamics Partner should provide consultation and advice on the architecture for your Dynamics 365 solution, to make sure the completed system will fit your true business needs.

1. Familiarize Yourself with Integration Templates

First and foremost, familiarize yourself with Microsoft’s helpful Dual-write mapping reference documentation, which contains links to all available Dual-write templates.

Each template provides details about which fields are synced between Dynamics 365 F&O and CRM, and in which direction they are typically synced, i.e., one-way or bi-directionally. In particular the Customers V3 (accounts) and Customers V3 (contacts) templates are a good place to start exploring, because most integrations involve sharing Customer information.

Here’s an example of a map as configured for a client:

Consider the Microsoft maps as the recommended approaches to integration. While deviating from these approaches is possible, and may be worthwhile for certain business needs, doing so will increase your project complexity and may require more advanced development and customizations.

A skilled Dynamics Implementation Partner like Encore can help you to choose and configure the mappings that strike the best balance of fitting your business’s processes and streamlining your Dynamics implementation.

2. Explore Global Address Book

Perhaps the most common cause of trouble with an integration between D365 CRM and F&O is a lack of familiarity with the Global Address Book (GAB).

GAB is a D365 F&O concept that is introduced to D365 CRM during an integration via Dual-write.

So, What Is the Global Address Book?

The Global Address Book in D365 F&O is a central data repository for all internal and external persons and organizations. Data is stored in Party records.

A Party is either a Person or an Organization, and may be associated with one or more Party Roles, such as customer, prospect, worker, user, contact, etc. Each Party may be related to one or more Locations, and have one or more Postal Addresses. Parties may also be associated with multiple Electronic Addresses (phone numbers, email addresses, or website URLs).

Because of this complexity, syncing Customer data between D365 CRM and Finance & Operations involves several other supporting Dual-write maps, not just the ones for Customers. Prepare to use other Dual-write templates, including CDS Parties, CDS Party Postal Address Locations, and Party Contacts (V3). The details can be found in Microsoft’s mapping reference.

3. Set Up and Configure in Both Environments

Plan to set up Dual-write at the beginning of the implementation project and link systems as soon as possible to avoid design roadblocks and customization rework. If you begin customizing or configuring before setting up Dual-write, you may have to redo substantial work.

Dual-write setup and configuration will happen in both the D365 Finance & Operations and D365 Customer Engagement environments. So, expect to have your D365 F&O administrators and D365 CE administrators working closely together.

As you move through the full integration, different parts of the Dual-write setup will need to happen in different places:

  • Dual-write apps are installed in the CE environment.
  • F&O and CE environments are linked from within F&O.
  • Integration maps are customized and managed from with F&O.
  • Integration mappings are stored in CE solutions.

4. Install Dual-write Apps

There are three Dual-write apps to install. This should be done as soon as your D365 Customer Engagement environment is provisioned and you have your main Dynamics 365 CE apps installed, e.g., Sales, Customer Service, and Field Service.

The Dual-write apps, which are available in Microsoft AppSource, are:

  • Dual-write Core Application
  • Dual-write Application Orchestration Solution
  • Dual-write Party and Global Address Book Solutions

Each of these apps includes multiple solution files. Each solution file is a bundle of customizations, and includes plugins.

Once Dual-write apps are installed in D365 CE, familiarize yourself with all the tables, forms, and fields that are imported into D365 CE with the Dual-write apps. Many custom components that impact the CE user experience are introduced in various solutions. Looking in the Dual-write solutions, like Dynamics 365 Finance Extended, Dynamics 365 GAB Extended, and Dynamics 365 Supply Chain Extended, is a good way to discern which native CE tables are impacted and which tables are newly created.

5. Prepare for Form Customizations

Spend some time inspecting new forms and note the new fields introduced to Dynamics 365 CRM through the integration with F&O. (New tables and fields will have msdyn_ prefixes.)

Make copies of the new main forms introduced for Accounts and Contacts (Customer Master and Contact Master) and use the copies as the basis for your customizations. Leave the original forms intact.

These new main forms contain tab sections for new types of related records that are involved in integration, such as Associated Contacts and Electronic Addresses. They also contain important custom scripts in their form libraries.

For each record type that will be synced via Dual-write, identify which D365 F&O fields are required to create and save a record in that system. Make sure those fields are present on your CRM forms (even if you introduce customizations to set those fields automatically in D365 CRM) to facilitate integration testing and troubleshooting.

Note that, in the backend of D365 CRM, “customization” is a term used for many of the built-in tools you will use in an integration with D365 F&O.

6. Review Business Rules

Review the numerous new Business Rules introduced to D365 CRM by the integration with F&O. These affect form behavior and the user experience, especially with Accounts where Relationship Type is equal to Customer. Expect many existing fields in your CRM applications to be locked after Dual-write installation.

Some examples of new Business Rules for the Account table include:

  • Default Relationship Type: This rule sets Relationship Type to Customer.
  • Lock Relationship Type: If the Relationship Type field is set to Customer, the field is locked for editing.
  • Make Customer Group Required: If Relationship Type is set to Customer, this rule makes Customer Group required.
  • Show/Hide Address 2 (Billing Address): If Relationship Type is set to Customer, this rule shows the Billing Address; otherwise it is hidden.
  • Show/Hide Customer Columns: If Relationship Type is set to Customer, this rule shows F&O-Customer fields, such as: Credit Rating, Customer Payment Method, On Hold Status, etc.

7. Consider Temporarily Deactivating Dual-Write Plugins

Dual-write plugins govern D365 CE record creation and update behavior by enforcing requirements for key fields on the D365 F&O side, like the Account record Company field (msdyn_Company), which references a D365 F&O legal entity, and Customer Group (msdyn_customergroupid).

After Dual-write apps installation and before Dual-write maps are turned on, when you attempt to save new records in D365 CE, plugins will raise errors when these important fields are left blank. You may opt to turn off Business Rules and Plugin Steps related to Dual-write in D365 CE until you are ready to turn on Dual-write maps and perform an initial sync of data to populate tables that support Customer integration, like Legal Entities, Customer Groups, Currencies, etc. See below for some specific errors and troubleshooting.

If your F&O configuration is already complete or your CE customizers are willing to wait until it is, you may not encounter these problems.

8. Set Up Autonumbering

In an integration between Dynamics 365 CRM and Finance & Operations, you must ensure that it is not possible for both systems to generate the same number for Customer records.

That’s because record number sequences, like those used to create unique Customer account numbers and sales order numbers, are not automatically connected. If your integration involves a bi-directional sync of Customer accounts between F&O and CRM, with users potentially creating new customers in each system, you must plan for separate customer number sequences or create a non-overlapping number range for each app.

In CRM, although built-in autonumbering does exist for some record types, such as sales quotations and orders, there is no built-in autonumber feature for Accounts. To deal with this solution gap, there are three different options:

  1. Create a custom autonumber field in CE.
  2. Develop your own custom autonumbering solution.
  3. Use a third-party tool to create and manage autonumbering for CE records.

The best solution will depend on details of your implementation plan. Consult with your Dynamics Partner.

Troubleshooting: Dual-Write Apps Not Syncing with Finance & Operations

If Dual-write apps are installed in Dynamics 365 CE but not yet syncing with F&O, users attempting to create test Account records in CRM may receive Business Process Errors like these three:

  1. “Write failed for entity CustCustomerV3Entity. Table validations error – Field ‘Customer group’ must be filled in.”
    Resolving this error requires setting up Customer Groups in F&O and performing an initial sync to populate the CE tables.
  2. “Unable to fetch entity CustCustomerV3Entity record. All primary column CustomerAccount, values are blank – ”
    Resolving this error requires setting up an Account autonumber solution in CE.
  3. “Write failed for entity CDS postal address history V2 with unknown exception – The value ‘WA’ in field ‘State’ is not found in the related table ‘States’.\nvalidateField failed on field ‘LogisticsPostalAddressBaseEntity.State'”
    Resolving this error requires setting up State records in F&O and preventing users from entering values that are not present in the F&O table. Consider adding a custom CRM table for States, using Dual-write to sync the custom States table to F&O, and add custom State lookup fields to CRM forms that have addresses. If customization is not desired, make sure users are trained to enter only those state abbreviations which are valid for F&O.

For more troubleshooting tips focused on the F&O side of the integration, read Troubleshoot Dual-write issues – Finance & Operations.

Additional Resources

Here are some additional online resources to help you learn more about Dual-write integration. If you are considering a Dynamics 365 implementation and would like help planning your path forward, please reach out to us.

Your Microsoft Dynamics Implementation Partner

Many customers come to us for their first Dynamics implementation. Others want to add a new solution to their Microsoft stack. And others ask for help with ongoing but troubled implementations.

Learn About Implementation Services

Your Dynamics Implementation Partner

Learn About Services