Академический Документы
Профессиональный Документы
Культура Документы
Program Name:
Description:
WR / CR/ Iss No.
Developer:
Reviewer:
Review Date
Note:
Sl.No Program Objects
Program Definition
Attributes
1 Program Name(Comply with the Customer Quality Standards)
2 Title of the program (Format: TO Description -TO Number)
3 Type(1-Online,M-Module pool,etc)
4 Status(This should always be ‘K’ for ABAPs developed by anyone other than SAP).
5 Application (this should correspond to the third character of the name).
6 Development Class(Give the Relavant Development Class)
7 Authorization Group (If Type is ‘I’, an authorization group is not needed).
8 Check for the usage of Logical Database. If not found there should be valid reasons for not using
LDBs.Please note that "Not specified in the Specification" is not a valid reason( LDB should be
the 1st option .Select to be used only if LDB is not available )
Text Elements
9 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 hard coded in the
program.Must use Text-symbols for this.
Program History Documentation
Data base selections, [ 1)Check the use of * in select statements, preferable to have a field list
always( Select * to be used only when more than 1/3 of the total fields required for processing for
the DB table_ 2)Check the usage of Start & End-of-Selection events where ever necessary]
SY-SUBRC is checked after database calls and other activities when logic must be used for Error
Handling.
When an internal table needs to be created directly from one database table,the SELECT INTO is
used to fill the internal table.It is faster to use INTO version of a SELECT statement rather than
use APPEND
Avoid SELECT …. ORDERBY .Better to use SORT after appending into an Internal Table.
Where Clause
For Transparent or Pool Tables ,the SELECT statement is fully qualified as much as possible with
the WHERE option, including data fields that are not part of the key
For Cluster tables,only the consecutive fields that are part of the key are qualified in the WHERE
option .The CHECK Command is used to eliminate other records .
The ordering of the WHERE Statements match the arrangement of the keys in the table records.
Fields compared in the WHERE clause of the SELECT statements have similar types.
The use of negative logic in SELECT's is avoided whenever possible .
When using the AND or OR operator ,the most likely elimination criteria is specified first,and so on
down to the least likely criteria.
Aggregrate functions (SUM,AVG,MIN,MAX) shall be used whenever possible
Primary Key Used - Whenever possible ,the full table key is specified and SELECT SINGLE is
specified
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 comparisons for equality .
A Secondary Index has been considered if :
1) Non-key fields or fields for which index support does not exist are repeatedly used to make
selections.
2) Only a small part of a large table is selected .(<5%)
3) The WHERE condition of the SELECT is simple .
4) Fields that make up the index significantly reduce the selection set of records by matching the
unique Qualifiers in the WHERE clause .
For relation operators Use 'EQ' 'GT' 'LT' 'GE' 'LE' instead of
symbols '=' '>' '<' etc…
Note : Prior to creating secondary indexes ,consultation with the Database administrator is
required.
Data Processing
Avoid Negative Logic
Use Structured Coding Style .Avoid the use of 'STOP' & 'EXIT' in the program .
Exit Should be used only when there is no other structured method for exiting a Loop or Form
Currency Calculations are performed between currency fields only - Both fields must have the
Same Currency key.
Calculations of fields with a Unit of Measure - Both fields must have the Same UOM .
ALL CASE statements must have a WHEN OTHERS statement to capture unexpected errors.
All LOOPS,Ifs,CASEs and similar statements are broken down to their simplest form and nesting is
not complicated unless absolutely necessary
MOVE statements - when possible ,the destination operands are kept as the same data type as
the source operands
CASE statement preferred to multiple ELSEIFs .
WHILE preferred to DO .
CLEAR command - CLEAR <field> is used to initialize rather than explicit moves.
Table headers and work areas are CLEARed at the end of loop processing .
MOVE CORRESPONDING is only used for small tables or tables where most but not all ,fields
need to be moved .
when all fields need to be moved and the attributes for every field and Position are identical ,the
table is moved as a group
When COLLECT semantics are needed,the COLLECT command is used .
21 If function modules used ,every error message should be captured and processed accordingly .
22 Where output/Error/Status is written a comment should be added for easier understanding .
23 If error messages occur the processing of report should be stopped .
24 The “Pretty Printer” function has been used to line up the code.
25 Usage of STD includes(YGSITOPPAGE,YGSIENDREPT)
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 the 'CTS Number' within the comment
26 string in the editor
27 Check for any kind of Delete statements.If found check with the developer if it is really required.
28 Check for any division by Zero
An Extended Syntax Check has been run on tha ABAP Program . The Run time Trace Analysis
29 (SE30)
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 coding run during the program
30 execution .
Documentation
31 User Documentation in SE38
32 Comments on events
33 Comments on processing blocks
34 Comments on every PERFORM subroutine call
35 Comments on every FUNCTION call
36 Comments for every Include program statement
37 Documentation for each PERFORM Subroutine
38 Documentation for each Include Program
Programming
Modularization &
Optimization
48 Spacing : Please leave blank lines between coding structures or clearly definable coding blocks.
The Standard structure for coding a ABAP Program has been followed as outlined in the
49 Development Standards Document
50 Modularize code - Forms Should be used to group Logical Segments of Code.
51 Modularize the code as much as possible using FORM Routines .
52 Putting Common pieces of code in FORM routines is also recommended.