ABAP Keyword Documentation → ABAP - Dictionary → ABAP CDS in ABAP Dictionary → ABAP CDS - Annotations → ABAP CDS - Specifying Annotations → ABAP CDS Metadata Extensions → ABAP CDS - DDL for Metadata Extensions → ABAP CDS - ANNOTATE ENTITY, VIEW
ABAP CDS - ANNOTATE, element_list
Specifies annotations for the following:
The parameters in a CDS metadata extension introduced using ANNOTATE. A semicolon-separated list element1; element2; ...; prefixed with annotations element_annot can be specified in the curly brackets of the statement ANNOTATE. There must be a semicolon after the last element of the list.
Each specified element element should appear in the SELECT list of the entity that is annotated using ANNOTATE. If not, the syntax check produces a warning. An externally visible element name must be used. This is either the direct name, an alternative element name defined with AS, or the name defined in a name list.
All elements of the SELECT list can be used exactly once. Valid SAP annotations @element_annot can be specified before these as element annotations. It is not possible here to specify annotations after the name of an element element with the syntax @<element_annot.
At least one element annotation @element_annot must be specified before each element of the list. However, the curly brackets of the ANNOTATE statement can also be empty.
- An element must be specified directly with its name. It cannot be specified using names with multiple parts separated by periods, which can be used within the entity for its definition.
- Element annotations can be specified here only if this is allowed in their annotation definition using the annotation @MetadataExtension.usageAllowed:true.
- An element that is not in the element list of the entity is handled like a normal element in the evaluation of annotations with the class CL_DD_DDL_ANNOTATION_SERVICE.
- The program ABAP_DOCU_MDE_ANNOS shows all annotations that can be specified in metadata extensions.