Get Example source ABAP code based on a different SAP table
• ASSOCIATION TO PARENT ON ABAP_CDS_DEFINE_CUSTOM
ABAP_CDS_DDL - DEFINE CUSTOM ENTITY, To-Parent Association
ABAP_SYNTAX ... ASSOCIATION TO PARENT target ON $projection. cds_cond ...
What does it do? Defines a CDS to-parent association in the element list of a CDS custom entity. The CDS to-parent association associates the current CDS entity, as a association source, with the association target target specified in the definition of the CDS to-parent association. CDS to-parent associations are specialized CDS associations and the same rules apply as described in topic CDS DDL - CDS View Entity, ASSOCIATION TO PARENT. The only difference is that the addition AS_assoc is not used. The name of the CDS composition is declared using the name _to_parent in the element list of the CDS custom entity.
ABAP_EXAMPLE_VX5 The following DDL source code shows a CDS custom entity that defines a CDS to-parent association to another CDS custom entity: DDLS DEMO_SALES_CUSTOM_CHILD ABAP_EXAMPLE_END