
TYPES t_t_type TYPE STANDARD TABLE OF T000.
CONSTANTS c_i TYPE p LENGTH 8 DECIMALS 14 VALUE '3.14159265358979'.
CONSTANTS x TYPE c LENGTH 1 VALUE 'X'.
CONSTANTS con_np TYPE REF TO object VALUE IS INITIAL.
DATA g_dmbtr TYPE dmbtr.
DATA gv_x TYPE char1.
DATA: lt_result TYPE t_t_type,
wa LIKE LINE OF lt_result.
element information during an analysis
Unfortunately, legacy code has normally some more disadvantages. Without a thorough understanding (runtime analysis) and appropriate test data, you would rather not make any changes. Don't even change a data type, variable or constant name unless you are very brave, like gambling or are otherwise very willing to take risks 😉
How can you create now some informative value without risk? ABAP Doc allows us to describe data types, variables and constants using suitable ABAP Doc comments. In connection with the ABAP Development Tools and the element information (F2 key) you can display this documentation at any time when data type, variable or constant is used in the source code. This helps during the analysis of the source code a lot.
"! table type for client customizing
TYPES t_t_type TYPE STANDARD TABLE OF T000.
"! number Pi
CONSTANTS c_i TYPE p LENGTH 8 DECIMALS 14 VALUE '3.14159265358979'.
"! used like abap_true
CONSTANTS x TYPE c LENGTH 1 VALUE 'X'.
"! null pointer
CONSTANTS con_np TYPE REF TO object VALUE IS INITIAL.
"! amount in local currency
DATA g_dmbtr TYPE dmbtr.
"! test switch, <strong>clear to write to database</strong>
DATA gv_x TYPE char1.
"! table with client customizing
DATA: lt_result TYPE t_t_type,
"! line of table lt_result (client customizing)
wa LIKE LINE OF lt_result.
element information with ABAP Doc comment
more information to transport via ABAP Doc comment
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
3 | |
2 | |
2 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |