Unify and manage your data

Mapping example 4

Mapping a DT Reference attribute to a CT Nested attribute

A reference attribute in a DT can be mapped to a nested attribute in a CT. In the following example, the Address reference attribute in the DT is mapped to the Address nested attribute in the CT. Here the DT uses the Location entity and HasAddress relation type to store address details via a reference attribute.

The DT entity types and relation types may not exist in the CT (Location and HasAddress) and do not need to be created there. The DTSS will resolve the mapping. Wild cards (*) can be used to copy all attribute values from the DT to the CT but only attributes with identical names between DT and CT will be mapped.

{
  "copyFromDT": "configuration/entityTypes/HCP/attributes/Address",
  "copyToCT": "configuration/entityTypes/HCP/attributes/AddressNested",
  "attributes": [
    {
      "copyFromDT": "configuration/entityTypes/HCP/attributes/Address/attributes/*",
      "copyToCT": [        "configuration/entityTypes/HCP/attributes/AddressNested/attributes/*"
      ]
    }
  ]
}

Or