CDS Annotation Reference
CDSNewComplete reference for SAP CDS annotations: @UI, @OData, @Search, @Analytics, @AccessControl, @Consumption, and @Metadata. With examples and Fiori Elements rendering.
Advertisement
About CDS Annotation Reference
CDS annotations like @UI, @OData, @Search, @Analytics, @AccessControl, @Consumption, and @Metadata each control a different aspect of how a view surfaces in Fiori Elements or gets exposed via OData, and the syntax for the less common ones is easy to forget. This reference documents each annotation family with examples and a note on how it renders in a Fiori Elements List Report or Object Page.
How to use this tool
- Browse annotations grouped by family (@UI, @OData, @Search, @Analytics, @AccessControl, @Consumption, @Metadata).
- Read the example syntax for the specific sub-annotation you need (e.g. @UI.lineItem, @UI.selectionField).
- Check the Fiori Elements rendering note to confirm the annotation produces the UI behavior you expect.
- Copy the annotation snippet directly above the relevant field in your CDS view definition.
All processing happens locally in your browser. No data is sent to any server. Your SAP code and business data remain private at all times.
Frequently Asked Questions
Where are CDS annotations documented?
SAP documents CDS annotations in the ABAP Keyword Documentation (transaction ABAPDOCU) and on help.sap.com. The @UI annotations for Fiori Elements are also documented in the SAP Fiori Elements documentation and the Flexible Programming Model guide.
What is the difference between @UI.lineItem and @UI.fieldGroup?
@UI.lineItem controls which fields appear as columns in a List Report table. @UI.fieldGroup groups fields into sections on an Object Page form. Both accept a position property to control ordering.
Do I need all annotations for a CDS view to work with Fiori Elements?
No. Fiori Elements uses defaults when annotations are missing. However, to control the exact UI layout, labels, value helps, and behavior, you need explicit annotations. The minimum for a working List Report is @UI.lineItem on at least one field and a proper @OData.publish: true or service definition.
Advertisement