Database Reference
In-Depth Information
11.1.3.3 Internal Tables
These tables are temporary and exist only during the run of an ABAP program. ABAP provides
various operations for processing internal tables such as sorting, searching, and sequential access.
When a similar processing has to be done on a subset of records from the database tables,
defining internal tables helps to simplify the programming effort by using control statements such
as DO loops and CASE.
11.1.3.4 SAP Transactions
A transaction in SAP is like a program in normal computer languages and is identified by a
four-character transaction code. A transaction can be initiated directly from the command field
on the presentation interface or from the corresponding menu option. There are two kinds of
transactions: report and dialog transactions:
1. Report Transactions : Report transactions are SAP programs that collect selection parameters
from the selection screen followed by the output called the lists.
2. Dialog Transactions : Dialog programs consist of more than one interactive screen called
a dynpro. These transactions sometimes also need preselected information for triggering
them, not unlike the explicit selection screens in report programs; these are called parameter
transactions:
a. Subroutines : As in any other programming language, ABAP allows subroutines for mod-
ularization of programs. This helps in reusability and, therefore, in increased quality,
productivity, maintainability, and documentation of the developed system. ABAP pro-
vides for definition of subroutines using the FORM language element. Subroutines can
be called by using PERFORM statements, and they can be called from within programs
or from external programs.
Here are other characteristics of subroutines:
i. Parameters of any type can be passed to subroutines.
ii. Calls can be generated dynamically during the processing.
iii. Calls can be nested, recursive, and so on.
b. Functions : Functions, which are a special kind of subroutine, are very important for the
modularization of ABAP programs and applications. Function modules are available in a
central library and can be called from there by any ABAP program. Function modules are
encapsulated objects and have clearly defined interfaces with parameters such as import,
export, and table parameters. Function modules have facilities for programming the han-
dling of exceptional situations that occur during the processing of these functions.
11.1.3.5 Reporting
Reports access one or more tables and display their contents in the form of a list, which can be
viewed either on the screen or on a printout. Report programs are very similar to the report pro-
grams in other languages, such as COBOL:
Logical Databases : For reporting data, reports might have to access several logically dependent
tables. Consequently, the report program has to establish a connection with the concerned
tables every time. Because many reports refer to the same set of tables, such requirements
Search WWH ::




Custom Search