ABAP Keyword Documentation → ABAP Dictionary → ABAP CDS in ABAP Dictionary → ABAP CDS - Syntax
ABAP CDS - Language Elements
The following sections summarize the language elements of the DDL and DCL of the ABAP CDS, arranged by topics.
In addition to the language elements show here, CDS source code can also contain annotations for metadata.
Other versions:
7.31 | 7.40 | 7.54
DDL
CDS Views
Keywords and Additions
Language Element | Meaning |
---|---|
DEFINE VIEW ... AS | Defines a CDS view |
WITH PARAMETERS | Defines input parameters of a CDS view |
SELECT [DISTINCT] ... FROM | SELECT statement of a CDS view |
INNER JOIN ... ON | Inner join in a SELECT statement |
LEFT | RIGHT OUTER JOIN ... ON |
ASSOCIATION ... TO ... AS ... ON | Defines an association for a path expressionin a SELECT statement |
1: | Attribute of a path expression |
INNER ... WHERE | Attribute of a path expression |
LEFT OUTER ... WHERE | Attribute of a path expression |
KEY ... AS | Element of a SELECT list |
$EXTENSION.* | Elements of an enhancement in a SELECT list |
WHERE ... | WHERE clause of a SELECT statement |
GROUP BY ... | GROUP-BY clause of a SELECT statement |
HAVING ... | HAVING clause of a SELECT statement |
UNION ALL ... | UNION clause of a SELECT statement |
Expressions
Operators | Meaning |
---|---|
MAX,MIN, AVG, SUM, COUNT | Aggregate expressions in a SELECT statement |
+,-, *, / | Arithmetic expressions in a SELECT statement |
CASE, WHEN, THEN, ELSE, END | Case distinctions in a SELECT statement |
CAST | Casting expression in a SELECT statement |
=,<>,<,>, <=, >=, BETWEEN,LIKE,IS NULL,NOT,AND, OR | Relational expressions in a SELECT statement |
Predefined Functions
Function | Meaning |
---|---|
ABS, CEIL, DIV,DIVISION, FLOOR, MOD,ROUND | Numeric functions in a SELECT statement |
CONCAT, LPAD, REPLACE,SUBSTRING | String functions in a SELECT statement |
COALESCE | Coalesce function in a SELECT statement |
CURRENCY_CONVERSION,UNIT_CONVERSION,DECIMAL_SHIFT | Conversion functions in a SELECT statement |
CDS View Enhancements
Keywords and Additions
Language Element | Meaning |
---|---|
EXTEND VIEW ... WITH | Enhancement of a CDS view with anCDS view enhancement |
DCL
CDS Roles
Keywords and Additions
Language Element | Meaning |
---|---|
DEFINE ROLE ... GRANT SELECT ON | Defines a CDS role |
WHERE, AND, OR | WHERE clause in the definition of a CDS role |
... = ASPECT pfcg_auth ... | Condition for mapping roles |
... = | <> |
... = | <> |
CDS Access Policies
Keywords and Additions
Language Element | Meaning |
---|---|
DEFINE ACCESSPOLICY | Defines a CDS access policy |
DEFINE ASPECT ... AS | Defines a CDS aspect |
SELECT FROM | SELECT statement of an CDS aspect |
WHERE $user IN | WHERE clause of the SELECT statement of an CDS aspect |