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

Community site session details

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

Composite Entity for three tables

(0) ShareShare
ReportReport
Posted on by 4,624

Hi

I have 3 tables with following relations with each others: -

1. TableA - Header table

2. TableB --  LineTable   -- it has relation with TableA ( TableA.fieldA == TableB.FieldA)

3. TableC --  LineTable   -- It has relation with TableB (TableB.fieldB == TableC.fieldB)

I need to create composite entity with all these three tables however i have individual entities for all these 3 tables already. I have seen MS docs explaining composite entity but that is for only 2 tables. Please suggest

I have the same question (0)
  • Verified answer
    André Arnaud de Calavon Profile Picture
    299,249 Super User 2025 Season 2 on at
    RE: Composite Entity for three tables

    Hi Rohin,

    You can actually include more than one child entity. Have a look at the composite entity 'Sales orders composite V3'. This one is having the sales order header, sales order header charges, sales order lines and sales order line charges as child entities.

  • Verified answer
    Blue Wang Profile Picture
    on at
    RE: Composite Entity for three tables

    Hi Rohin,

    "I have seen MS docs explaining composite entity but that is for only 2 tables".

    A composite entity is a concept that allows you to build a single entity by leveraging multiple entities that are related to each other.

    https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/data-entities/develop-composite-data-entities

    You can find examples containing multiple entities in AOT.

    1050.PNG

  • Martin Dráb Profile Picture
    236,316 Most Valuable Professional on at
    RE: Composite Entity for three tables

    Note that you can also create a normal (non-composite) entity using either those three tables or those three entities as data sources.

    The choice depends on what you need to achieve.

  • Rohin Profile Picture
    4,624 on at
    RE: Composite Entity for three tables

    Martin , what is benefit or I would say when should i choose Non- composite entity over composite ? please elaborate more

    Thanks

  • Verified answer
    Martin Dráb Profile Picture
    236,316 Most Valuable Professional on at
    RE: Composite Entity for three tables

    Composite data entities are very limited - for example, they don't support OData and any data format except of XML (no CSV, Excel etc.). Therefore you use them just under very specific conditions. Otherwise you either join tables to a single entity, or you use multiple entities separately (e.g. you export headers and lines to two separate files).

    Don't forget that one of the purposes of data entities is simplifying the schema, e.g. joining all related tables together and exposing them as a single logical entity. For example, the customer entity contains not only CustTable, but also DirPartyBaseEntity, LogisticsPostalAddressBaseEntity, DimensionSetEntity and so on.

  • Verified answer
    Blue Wang Profile Picture
    on at
    RE: Composite Entity for three tables

    A composite entity cannot be used for Odata, it will only be supported from a data management platform. There is no programmatic interface for composite entities in X++. It is only supported for a data management platform that is part of XML file-based imports/exports.

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…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

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

#1
CA Neeraj Kumar Profile Picture

CA Neeraj Kumar 2,157

#2
André Arnaud de Calavon Profile Picture

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

#3
Sohaib Cheema Profile Picture

Sohaib Cheema 674 User Group Leader

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans