4.4 Introduction to the TYPE Concept (4.4.4 Data Objects (Constants…
4.4 Introduction to the TYPE Concept
4.4.4 Data Objects
accessed using the syntax text-nnn, where nnn is the text symbol number
behaves like a constant and has the data type c with the length defined in the text element
not declared in the program itself
defined as a part of the text elements of the program
mandatory to use the addition VALUE to assign an initial value
can be reused and maintained centrally
content cannot be changed
contents can be changed via ABAP statements
generates a screen field (selection screen)
defines a variable
defines a variable
not reusable data objects and contents can'be changed, unnamed data objects
alphanumeric characters in the source code of the program enclosed in single quotation marks (') or back quotes (`)
with back quotes
have the predefined type string
in single quotes
have the predefined typ c
text field literals
not support decimal separators or notation with a mantissa and exponent
are declared in the ABAP program and are local to the program
describes the technical attributes of a field
If you plan to create multiple data elements that are technically the same, you can attach a domain to derive the technical attributes of a data element.
create the domain while creating the data element
create the domain separately first and attach it to a data element
change the technical attributes once for the domain, and the change will be reflected automatically for all the data elements
The primary function of a domain is to define a value range that describes the valid data values for the fields that refer to this domain.
4.4.2 Data Elements
If you change the definition of the data element, the changes will be automatically reflected for all the objects referring to that data element.
The global user-defined elementary types are called data elements and are created in ABAP Dictionary
4.4.1 Data Types
describe reference variables (data references and object references)
Complex Data Types
work with interrelated data types under a common name
are made up of a combination of other data types and must be created using existing data types
Elementary Data Types
specify the types of individual fields in an ABAP program
User-defined Elementary Types
be declared locally in the program using the TYPE keyword or define them globally in the system in ABAP Data Dictionary
Predefined Elementary Data Types
The conversion rule for a TYPE c source field and a TYPE i target field is that they must contain a number in commercial or mathematical notation.
If you move data between dissimilar data objects, then the system performs type conversion automatically by converting the data in the source field to the target field using the conversion rules.
Predifined Elementary ABAP Types with Variable Length
there can be situations in which you need a field with dynamic length because you won't know the length of the data until runtime
This is a hexdadecimal type with a variable length.
The data x interprets individual bytes in memory.
2 more items...
It can contain any number of alphanumeric characters.
This is a character type with a variable length.
The field length for data types f, i, int8, decfloat16, decfloat34, d, t is fixed.
numeric character string
decimal floating point number with 34 decimal places
decimal floating point number with 16 decimal places
binary floating-point number