Keywords must be all uppercase, all lowercase, or in lowercase with an uppercase initial letter. Other mixes of uppercase and lowercase are not allowed.
Names
Names are not case-sensitive.
A name can have a maximum of 30 characters.
A name can consist of letters, numbers, underscores (_), and slashes (/).
A name must start with a letter, slash character, or underscore. Underscores are recommended as the naming convention for associations.
The separator for names with multiple parts is a period (.). Names with multiple parts can be paths, columns with a prefixed data source, and structured annotations.
The following CDS keywords cannot be used as names: ALL, AND,
AS, ASSOCIATION, AVG,
CASE, CAST, CROSS,
COUNT, DISTINCT, EXISTS,
EXTEND, FROM, FULL,
GROUP, HAVING, INNER,
JOIN, KEY, LEFT,
MAX, MIN, NOT,
NULL, ON, OR,
ORDER, RIGHT, SELECT,
SUM, UNION, VIEW, WHEN, WHERE
Literals
Numeric literals must always be specified in full and a decimal point (.) used as a decimal separator if necessary.
Character literals are enclosed in single quotation marks (').
Comments
Two forward slashes (//) introduce a comment, which continues until the end of the line.
Comments within lines or that span multiple lines are enclosed by the characters /* and */.
Separators
Statements can be closed using a semicolon (;). Sometimes this is mandatory.
Protected words
Certain keywords are protected and cannot be used as self-defined names. The reserved names that cannot be used are specified in the database table TRESE.
Notes
The closing semicolon after a statement is sometimes optional because one piece of CDS source code can currently only contain a single statement.