Abap Code Review Check List
Abap Code Review Check List
Tech
ABAP Code Review Checklist
Quality
Procedures
Project : <Project Name> Final Review Status
Developer Auditor
File name : ABAP Code Review Checklist_I/E_nnnn,I-Interface,E-enhancement Status status
ZV1U_ESO_CREATE_ORDER (Webdynpro
Progra Component) class : ZV1U_ESO_CREAT_ORDER_ASST
m method COST_CENTER_VALIDATION
Name:
Description:
Developer: Santhosh Kumar Konda
Auditor: Seshagiri Ravi Kiran Y
Audit Date
Sl.No Program Objects
Program Definition
Attributes
1
Program Name should begin with ZAXXX_A(A - Application area ; sss -
Subcategory - REP for reports, IN for inbound interface, OUT for outbound
interface etc. NA NA
XX = system name (1U, DAM).
2 Title of the program NA NA
4 Status(This should always be ‘K’ for ABAPs developed by anyone other than NA NA
SAP).
5 Application (This should always be 2nd and 3rd character of the name) NA NA
6 Ex. Y_REPORT) NA NA
7 Authorization Group (If Type is ‘I’, an authorization group is not needed). NA NA
Text Elements
8 Title and Headers
If the report definition says ‘no standard page headings’ or if no report is
produced in the ABAP, then these can be blank; otherwise they must be
filled in. Normally this comes from the title given in the attributes.
Selection Texts
If the ABAP uses Selection Options or Parameters, they must be documented
here.
Text Symbols
Texts which are used in cloumn headings, Write statements should not be NA NA
hard coded in the program.Must use Text-symbols for this.
8 b) Selection Texts NA NA
8 c) Text Symbols should be provided with string associated with text
element Ex: 'Customer Name'(001) NA NA
Program History Documentation
SELECT FOR ALL ENTRIES used outside of loops, with a read used inside the NA NA
loop.
Nested SELECTS and Loops - these are avoided through the use of a
dictionary NA NA
VIEW or by using FOR ALL ENTRIES appendage to the SELECT statement.
1) If FOR ALL ENTRIES is used, the table size is verified > 0. NA NA
2) If key fields are not used, the DELETE ADJACENT command should be
used - if appropriate. NA NA
The ordering of the WHERE Statements match the arrangement of the keys
in the table records. NA NA
Secondary Index Usage - When possible ,in the Where clause the fields of
the INDEX are in the specified order and linked by the logical AND with NA NA
comparisons for equality .
A Secondary Index has been considered if : NA NA
1) Non-key fields or fields for which index support does not exist are
repeatedly used to make selections. NA NA
2) Only a small part of a large table is selected .(<5%) NA NA
3) The WHERE condition of the SELECT is simple . NA NA
4) Fields that make up the index significantly reduce the selection set of
records by matching the unique Qualifiers in the WHERE clause . NA NA
For relation operators Use 'EQ' 'GT' 'LT' 'GE' 'LE' instead of NA NA
symbols '=' '>' '<' etc…
Note : Prior to creating secondary indexes ,consultation with the Database
administrator is required.
Data Processing
14 Avoid Negative Logic NA NA
Use structured coding style - do not use “STOP” to halt a program. The use
of “EXIT” should be used only when there is no other structured method for
exiting a loop or form. NA NA
or Form NA NA
Currency Calculations are performed between currency fields only - Both
fields must have the Same Currency key. NA NA
All LOOPS,Ifs,CASEs and similar statements are broken down to their
simplest form and nesting is not complicated unless absolutely necessary NA NA
MOVE statements - when possible ,the destination operands are kept as
the same data type as the source operands NA NA
CASE statement preferred to multiple ELSEIFs . NA NA
WHILE preferred Over DO . NA NA
CLEAR command - CLEAR <field> is used to initialize rather than explicit NA NA
moves.
Table headers and work areas are CLEARed at the end of loop processing . NA NA
MOVE CORRESPONDING is only used for small tables or tables where most
but not all ,fields need to be moved . NA NA
when all fields need to be moved and the attributes for every field and
Position are identical ,the table is moved as a group NA NA
When COLLECT semantics are needed,the COLLECT command is used . NA NA
Done
Extracts-All fields involved in sort options ( user specified / hardcorded in the
15 abap program) of the output data shall be the part of the fieldgroup'Header'. NA NA
16 Internal Tables-Nested Loops are avoided . NA NA
Use APPEND LINES OF <I_table> to merge two internal tables . NA NA
APPEND SORTED BY used only for reportrs such as "TOP 50" or "TOP 100" . NA NA
For reading ,LOOP …. WHERE is used instead of LOOP/CHECK . NA NA
For READ operations ,the key fields are specified for the READ access NA NA
explicitly .
when performing direct reads,the BINARY SEARCH is used only when the
table contains more than 500 rows and must be sorted by the key Done Done
REFRESH <table> is used to initialize table records .Internal tables are
REFRESHed when needed. NA NA
The FREE command is used to release the memory allocated to internal
tables when the program is finished processing the data in the table NA NA
SORT <itab> ORDER BY preferred over SORT ITAB NA NA
OCCURS clause - not used since we are setting the initial size for all internal NA NA
tables.
Messages
Every Message (Error/Information/Warning) in the program has a comment
17 beforehand for explanation . NA NA
If function modules used ,every error message should be captured and
18 processed accordingly . NA NA
Extended Code Check
Check for any unused code lines(i.e) Commented code lines in case of new
development and in case of TDL / PQR , the commented lines should have
19 the 'CTS Number' within the comment string in the editor Done Done
20 Check for any division by Zero NA NA
An Extended Syntax Check has been run on tha ABAP Program . The Run
21 time Trace Analysis (SE30) NA NA
The Run time Trace Analysis (SE30) has been used to evaluate the hit lists
of the top CPU consumers,table accesses,and to get a general idea of the
22 coding run during the program execution . NA NA
Documentation
23 History Documentations on every report/include program Done Done
Comments required if
New logic - Purpose of new logic why it has been added
Inactive logic - If any of the existing logic is commented, it should be clearly
why it has been commented
Complex logic - Detailed explanation is required if logic written is complex /
24 assumtions / forcasting the future issues Done Done
25 Comments on processing blocks like methods, subroutines, function Done Done
modules etc
Programming Modularization & Optimi
Spacing : Please leave blank lines between coding structures or clearly
26 definable coding blocks. Done Done
The Standard structure for coding a ABAP Program has been followed as
27 outlined in the Development Standards Document NA NA
28 Modularize code - Forms Should be used to group Logical Segments of Code. NA NA
29 Modularize the code as much as possible using FORM Routines . NA NA
Function Group & Function Modul
30 Function Group should start with Z_* NA NA
Completed
Remarks