web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Unanswered

Composite entity key

(0) ShareShare
ReportReport
Posted on by 464

Hi,

If we want to make a composite entity. Should the entity key of the main entity be repeated in all child entities?

I mean if let's say in the composite entity, the main entity was EntityA where the Entity key is fieldA and below this enity we have 2 other entities on the same level (Entity B and Entity C)

Should the entity key for EntityB and EntityC contain field A as a must with another unique field?

Another question,  can I create a composite entity with the entity repeated? I mean it consists of EntityA and EntityA?

I know it doesn't make sense but can we?

In this case, can the entity key for each one be fieldA only? Or should the main datasource have Entity key as fieldA and the other entity should have fieldA with RecId for example? 

I have the same question (0)
  • Martin Dráb Profile Picture
    237,722 Most Valuable Professional on at

    That child enitities in a composite entity are related to the parent entity through its entity key is a typical scenario. But it doesn't have to be true in all cases. A child entity could be related to a non-key field of the parent entity.

    I guess you could use the same entity twice in the same composite entity. You can simply try it to know it for sure.

    I don't understand the last question. The entity key should contains fields needed to uniquelly identify a record in the entity. It has nothing to do with whether it's used in a composite entity and how. Exposing RecIds would be wrong. It's meaningless to uses and other systems; youy should use a natural key instead.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Martin Dráb Profile Picture

Martin Dráb 687 Most Valuable Professional

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 535 Super User 2025 Season 2

#3
BillurSamdancioglu Profile Picture

BillurSamdancioglu 403 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans