ABAP Keyword Documentation → ABAP - Dictionary → Built-In Data Types in ABAP Dictionary
Use of the Built-In Dictionary Types
The built-in types in ABAP Dictionary are used for the definition of the elementary parts of all data types, including reference types in ABAP Dictionary, and for specifying some types in ABAP SQL and ABAP CDS. The built-in types in ABAP Dictionary cannot be specified directly in any places other those specified below:
- Reference types
- Types specified in SQL
- Typing of elements and input parameters of CDS entities in ABAP CDS.
- Cast expression cast in the CDS DDL in ABAP CDS
- SQL expression
CASTin ABAP SQL
The data type of all elementary components in a CDS entity, such as view fields, literals, parameters, and other operands is based indirectly on the built-in data types in ABAP Dictionary.
Unlike when using the data types above,
TYPE references to the built-in data
types in ABAP Dictionary are not possible in ABAP programs. Alongside their role in defining data types, these built-in types in ABAP Dictionary must also be considered in
ABAP SQL statements and when working with dynpros:
- ABAP SQL statements work with database tables defined in ABAP Dictionary whose columns have external data types to which the actual platform-dependent types of the databases are mapped.
- In Screen Painter, dynpro fields are also declared with reference to external data types. In a dynpro field, the special semantic attributes of its data type are usually significant and are evaluated for input masks and for checking input.
7.31 | 7.40 | 7.54
In ABAP development, only mappings from the built-in dictionary types to the built-in ABAP types are relevant. In database accesses using ABAP SQL, the actual database type, such as NVARCHAR, is obscured by the dictionary type (in this case CHAR).
The following type reference in an ABAP program does not use the built-in type INT2 directly. Instead, it used the identically named data element INT2 whose type is itself defined using the identically named domain INT2. Here, the built-in type INT2 is specified:
DATA num TYPE int2.