By Lorren Zemke, Director of Professional ServicesTuesday, September 5, 2017
Not all Dynamics 365 Entities honor setting the owner on an entity mapping but there is an additional message available to be able to map the owner for any entity (or record).
The first step is to un-map the owner column on the entity if it is currently set.
The next step is use the Assign Record message available in the CRM Destination.
Check the box “Include advanced messages”. This will now include additional steps that can be used within SmartConnect for processing data in Dynamics 365. The additional messages do not require any additional entities to be mapped and can be executed in their own mapping if so desired.
Double-Click on the “Assign record to a new owner(user or team)”, which will open the SmartConnect mapping window.
There are two different methods for mapping the Entity owner depending on the data you have available in your source.
Use an Entity Lookup.
Create the Entity Lookup and map it directly to the field in CRM
Use the Entity Reference.
Create an Entity Reference from the GUID in your source data or from the Entity Lookup and map it directly to the field in CRM
The examples below show how to create both the Entity Lookup and Entity Reference columns which may then be mapped to the Target and Assignee columns within CRM Mapping.
Create the Owner Entity Lookup
*This step is required if you do not already have the owner entity GUID as a source column.
Create an Additional column for the Owner Lookup to return the GUID of that entity, using whichever entity you are trying to set as the owner. We will use this column as our Entity Reference.
Create the Owner Entity Reference
Create an Additional column for the Owner Reference, whether that’s a user / team / etc.
NOTE: Reference field on this column is the GUID to the Owner entity. If the GUID is not in the data source then you would need to use an Entity Lookup created above in Reference field. If the GUID is in your source data, use that column in the Reference field.
Create the Target Entity Lookup
*This step is required if you do not already have the target entity GUID as a source column.
Create an Entity Lookup column that returns the GUID of Target Entity if the GUID is not part of the source file.
Create the Target Entity Reference
Create an Additional column for the Target Entity Reference, whether that’s an Account, Order, Invoice, Product, etc.
NOTE: Reference field on this column is the GUID to the Target entity. If the GUID is not in the data source then you would need to use an Entity Lookup created above in Reference field. If the GUID is in your source data, use that column in the Reference field.
*You can map either the Entity Reference or Entity Lookup to both assigned and target destination columns.
Map the User/Owner Reference or the User/Owner Entity Lookup to the Assignee.
Map the Account/Entity Reference or the Account/Entity Lookup to the Target.
Set the Group On to the entity reference or the entity lookup, whichever is mapped, so it only runs once for that entity should it happen to appear more than once in the source file.
Click “OK” in the SmartConnect mapping to close and save the mapping.
On the Map Setup window, click Run to execute the map.
When the map executes, it will now update the Owner of the mapped Entity.