SAP EXTENDED PROGRAM CHECK - Guide
Get Example source ABAP code based on a different SAP table
Extended Program Check
ABAP_BACKGROUND
You can call the
The extended program check reports errors, warnings and messages. The ATC-relevant check reports errors and warnings that are particularly critical. These checks are also performed in program checks in
In the initial screen of the extended program check, a programming guidelines check can also be selected. This checks whether certain rules presented in this book (that can be verified statically) have been adhered to.
The messages from the extended program check, which are inapplicable in some special cases, can be hidden using pragmas. Before the introduction of pragmas, it was not possible to hide messages raised by a regular syntax check.
Latest notes:
The extended program check also covers security checks used to test ABAP programs for all potential
ABAP_HINT_END
ABAP_RULE
Use the extended program check and take the results seriously. Message are not allowed to appear when the ATC-relevant checks are performed for a completed program.
ABAP_DETAILS
The errors, warnings and messages output by the extended program check are just as important as the syntax errors and syntax warnings from the
In rare cases, when a result reported by the extended program check is not justified, this must be documented using an appropriate pragma (the relevant pragma is indicated in the message). This means that the system suppresses the message of the extended program check. Ideally, in less obvious situations, an additional comment should be used to describe why the message is not applicable.
Latest notes:
The extended program check provides useful help for writing ABAP programs in the correct way. Using unspecific pseudo comments or pragmas can undo the positive effect of the extended program check. In particular, the following statement should never be used:
This statement suppresses all messages of the extended program check for an entire source code section.
If the ABAP program is submitted to a code review, the results of the extended program check should be used to evaluate the quality.
ABAP_HINT_END
ABAP_EXAMPLE_BAD
If the following source code is checked using the extended program check, a warning appears. It indicates a particularly questionable query of the content of the
IF sy-subrc <> 0.
...
ENDIF.>
The program section shows a typical error in a program with correct syntax. The developer wrongly assumes that the static form of the
ABAP_EXAMPLE_END
ABAP_EXAMPLE_GOOD
The following source code shows the corrected version of the above example. The predicate expression
IF <(>
...
ENDIF.>
ABAP_EXAMPLE_END