Ansicht
Dokumentation

ABAPSTRUCTURE_OF_DBTAB - STRUCTURE OF DBTAB

ABAPSTRUCTURE_OF_DBTAB - STRUCTURE OF DBTAB

Fill RESBD Structure from EBP Component Structure   Vendor Master (General Section)  
This documentation is copyright by SAP AG.
SAP E-Book

Line Structure of Database Tables

In ABAP, you can use TYPE to refer to the line type of a database table or view dbtab known to the ABAP Dictionary. The line type of a database table dbtab is a structure with the same name. The names and the sequence of the components in the structure dbtab correspond exactly to the names and the sequence of the fields in the declaration of the database table or view in the ABAP Dictionary. The ABAP data type (see DATA) and the length of the components are derived as follows from the data types in the ABAP Dictionary:

DD data type ABAP data type
ACCP N(6)
CHAR n C(n)
CLNT C(3)
CUKY C(5)
CURR n, m, s P((n + 2) / 2) DECIMALS m [NO-SIGN]
DEC n, m, s P((n + 2) / 2) DECIMALS m [NO-SIGN]
DATS D
FLTP F
INT1 no equivalent
INT2 no equivalent
INT4 I
LCHR n C(n)
LRAW n X(n)
LANG C(1)
NUMC n N(n)
PREC s
QUAN n, m, s P((n + 2) / 2) DECIMALS m [NO-SIGN]
RAW n X(n)
RAWSTRING XSTRING
SSTRING STRING
STRING STRING
TIMS T
UNIT n C(n)
VARC n C(n)

Notes

  1. The ABAP Dictionary data types INT1 and INT2 are integer data types and use up 1 and 2 bytes respectively. They have an initial value of 0.

  2. The length of the line structure is not simply the sum of the lengths of all fields. Depending on the alignment requirements of the various fields (Alignment), the structure may contain nameless "gaps".

  3. The devisions specified for determining the ABAP field lengths are integer divisions without rounding. For an even n, the corresponding field of the table work area can then hold numbers that contain one more digit than allowed by the ABAP Dictionary data type. However, this results in a runtime error when the data is written to the database.


Related

DATA, TYPES






rdisp/max_wprun_time - Maximum work process run time   Fill RESBD Structure from EBP Component Structure  
This documentation is copyright by SAP AG.

Length: 4628 Date: 20240416 Time: 201246     sap01-206 ( 51 ms )