FUNCTION OF THE ABAP DICTIONARY
The ABAP Dictionary performs three key functions:
The ABAP Dictionary enables central management of all the type definitions used in the R/3 System. You can use this tool to create data types, such as data elements, structures, and table types, either for ABAP programs or for applications, such as function modules and object methods.
The ABAP Dictionary also defines database objects such as tables, indexes, and views.
It also provides numerous services that support program development, such as setting and releasing locks, defining an input help, and attaching a field help to a screen field.
DATABASE OBJECTS IN THE ABAP DICTIONARY
You can define a table and a database view in the ABAP Dictionary independent of the database. On the basis of this definition, objects are created in the database shown here. Therefore, any further change in these definitions gets automatically reflected in the database.
You can also define indexes in the ABAP Dictionary to speed up access to data in a table. These indexes are created in the database.
TYPE DEFINITION IN THE ABAP DICTIONARY
Data elements describe an elementary type by its characteristics, such as the data type, length, and decimal places.
Structures consist of components that can have any type.
Table types determine the structure of an internal table.
Let us assume that the data of an employee is stored in a structure called EMPLOYEE, which has the components NAME, ADDRESS, and TELEPHONE.
The component “NAME” is again a structure with components “FIRST NAME” and “LAST NAME”.
Similarly, the component “ADDRESS” is also a structure with the components STREET and HOUSE NO.
However, the component “TELEPHONE” is defined by a table type as an employee can have multiple telephone numbers.
SERVICES OF THE ABAP DICTIONARY
input helps (or F4 helps) for screen fields that can be defined with search helps;
field helps (or F1 helps) for screen fields by creating documentation for the data element; and
input checks that ensure that the values entered are consistent.
LINKING TO THE DEVELOPMENT AND RUNTIME ENVIRONMENT
The ABAP Dictionary is well integrated in the development and runtime environments. Therefore, any change in the ABAP dictionary gets automatically reflected in the relevant ABAP programs and screens.
Let us discuss this concept with the examples shown here:
ABAP Tools and the Screen Painter use the information stored in the ABAP Dictionary to provide support services during program development. The Get from Dictionary function, which is defined in the ABAP Dictionary, is used in the Screen Painter to place fields of a table or structure.
ABAP Interpreter and the Screen Interpreter retrieve the type definitions from the ABAP Dictionary soon after a program or a screen is generated.
Database Interface utilizes table and database-related information stored in the ABAP Dictionary to access the data in these objects.