Forum Discussion

Milhis570's avatar
Milhis570
Copper Contributor
Mar 23, 2023

Writing data to a lookup field via alternative keys

Hi Folks,

 

I have 2 table, 

 

1. Contact with a secondary key

 

2. Policyholder with a lookup field to contact and a column that contain the contact secondary key guid as a string

 

 

I want to take the column named : contactSecondaryKeyString in policyholder which contain the secondary key string(guid) and push it to my lookup field policyholder in the table policy holder.

 

As per microsoft it is possible : Copy and transform data in Dynamics 365 (Microsoft Dataverse) or Dynamics CRM - Azure Data Factory & Azure Synapse | Microsoft Learn

 

Here is my mapping code : 

 

 

and I get the error : 

 

"ErrorCode=DynamicsOperationFailed,'Type=Microsoft.DataTransfer.Common.Shared.HybridDeliveryException,Message=,Source=,''Type=Microsoft.DataTransfer.Common.Shared.HybridDeliveryException,Message=Dynamics operation failed with error code: -2147217149, error message: 'prsc_phplan' entity doesn't contain attribute with Name = 'prsc_policyholder@prsc_systemid' and NameMapping = 'Logical'

 

I tried many variation and still can't figure it out...

  • Randy Slavey's avatar
    Randy Slavey
    Copper Contributor
    A year later, and I still find no solution to this. If I do it in a data flow, per the article above, I get the following. (FYI, xxx is the first part of the lookuptable@keycolumnvalue as described in the original question)

    An undeclared property 'xxx' which only has property annotations in the payload but no property value was found in the payload. In OData, only declared navigation properties and declared named streams can be represented as properties without values.

    If I try to do it in a copy data activity, I get the same error as above. I've tried lookuptable/keycolumn, lookuptable@keycolumn, lookuptable/keyname, and lookuptable@keyname, to no avail.
    • dpryde's avatar
      dpryde
      Copper Contributor

      Hi Randy

      Did you ever manage to get it to work? I'm trying to do the same thing using a copy data activity in Synapse and wondered if anyone had found a solution yet.

Resources