SAP BUILTIN TYPES BYTE



Get Example source ABAP code based on a different SAP table
  


• x ABAP_TYPE
• xstring ABAP_TYPE

Built-In Byte-Like Types
The data objects of the byte-like data types are used to store byte strings.

Properties TypeLengthStandard LengthMeaning Data Object ABAP_KEY x1 to 524,287 bytes1 byte Byte field type Byte field ABAP_KEY xstringVariable Byte string type Byte string

Value Ranges and Initial Values TypeValue RangeInitial Value xAny byte values, hexadecimal 00 to FFHexadecimal 00 xstringAs for type xEmpty string with length 0



Latest notes:

The byte-like data types are used for byte string processing.
For more about strings, see Strings.
The type x, for which a length interval is specified in the second column of the first table, is generic, which means that the length is not part of the type description. The entry in the column Standard Length specifies the length used in declarations of data objects when using types with generic lengths, if no explicit length is specified in the corresponding statement.
The system class CL_ABAP_ELEMDESCR contains a constant TYPE_X_MAX_LENGTH for the maximum length of the type x.
The maximum size of strings must be respected. If an operation with a string exceeds its maximum size, an exception of class CX_SY_STRING_SIZE_TOO_LARGE is raised and can be handled.
NON_V5_HINTS
ABAP_HINT_END

ABAP_EXAMPLE_VX5
Declaration of a byte string of the built-in ABAP type xstring for the result of a functional method. This declaration could also be made inline on the left side of the assignment.
ABEXA 00837
ABAP_EXAMPLE_END