Setting Multi Entity Lookups using Azure Data Factory

Finally you can handle Multi-Entity lookups using Azure Data Factory with the Common Data Service connector!

In several posts back in May 2020 (e.g. here) I was testing Azure Data Factory (ADF). Back then it was not possible to set multi-entity lookups such as “Customer” or “Owner” on using ADF and the Common Data Service for Apps connector, no matter whether you are creating or updating a Dynamics 365 record.

However from 10 June 2020, you can definitely do this now in ADF! Microsoft has finally introduced the target mapping that allows you to define the logical name of the entity you would like to set for a multi-entity lookup (see here for the updated documentation).

If your source table has a column containing the logical name of the target entity, simply map this to a new Common Data Service field:

{logical_name_of_lookup_field}@EntityReference

If all the rows you wish to migrate are actually targeting the same type of entity (e.g. they are all Contact to to be set in a customer field), you can even create a new column mapping and simply hard code the logical name (e.g. contact) directly.

This is a great addition to the ADF functionality. It allows us to now migrate Dynamics 365 Case (incident) records which wasn’t possible previously. This is because the multi-entity lookup “Customer” field is system required on a case record.

Note: as of June 2020 the following field types are still not supposed by ADF Common Data Service for app connector.

  • AttributeType. CalendarRule
  • AttributeType.MultiSelectPicklist
  • AttrbuteType.PartyList

However given Microsoft has finally fixed the multi-entity lookup problem, I remain hopeful that we can eventually handle all field types using ADF one day.

5 thoughts on “Setting Multi Entity Lookups using Azure Data Factory

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s