Skip to content

ABAP Keyword Documentation →  ABAP - Dictionary →  ABAP CDS in ABAP Dictionary →  ABAP CDS - Data Definitions →  ABAP CDS - DDL for Data Definitions 

ABAP CDS - entity_annot

Other versions: 7.31 | 7.40 | 7.54

Syntax

... @annotation ...

Effect

Specifies an annotation annotation as an entity annotation in front of the statement in the definition of a CDS entity.

The character @ must be placed in front of the name annotation of the annotation. The annotation should be defined as a CDS object in a CDS annotation definition and the annotation definition annotation @Scope should be specified here using the value #ENTITY.

The following tables show the possible ABAP annotations that can be specified and their meanings. The ABAP annotations are evaluated by the ABAP runtime environment for every CDS entity. Annotations with other identifiers are usually framework-specific annotations. These are not evaluated by the ABAP runtime environment but by other SAP frameworks instead.

The first column of the table displays the (possibly structured) name annotation of an ABAP annotation and the second column displays its meaning. The third column shows the possible annotation values. The fourth column shows the value set implicitly for the annotation value if the annotation is not used explicitly. The fifth column displays the default value set implicitly for value in accordance with the annotation definition if the annotation is specified without a value. If nothing is specified for the annotation value, the annotation should be specified without a value.

EndUserText Annotations

Translatable texts of the CDS entity.

Annotation Meaning Annotation Values Default Value if Not Used Default Value if Used Without Value
EndUserText.label Translatable short text of the CDS entity Character string with maximum 60 characters - -


Note

ABAP annotations introduced using EndUserText are used to define translatable semantic texts for a CDS object. The value of an annotation like this is saved in special tables that have a language key and that are translatable. The value specified in the source code should consist of text in the original language of the CDS source code and is translated into the required languages. The methods of the class CL_DD_DDL_ANNOTATION_SERVICE read these texts as specified by an input parameter for the language. If no language is passed to the input parameter, the text environment language is used as the default. If no text is found for the language, the secondary language in AS ABAP is used.

Metadata Annotations

Defines the handling of metadata from the CDS entity.

Annotation Meaning Annotation Values Default Value if Not Used Default Value if Used Without Value
Metadata.allowExtensions Defines whether annotations can be extended from metadata extensions true:
The current CDS entity can be extended. false:
The current CDS entity cannot be extended.
false true


Note

The CDS table functions cannot currently be extended. The annotation Metadata.allowExtensions can be specified for a table function but is currently ignored.


This translation does not reflect the current version of the documentation.