0% found this document useful (0 votes)
95 views9 pages

Abap Dictionary

The ABAP Dictionary (Tcode: SE11) is a central repository for managing data definitions in SAP systems, allowing for the creation of database tables, views, data types, and more. Key components include transparent, pooled, and cluster tables, as well as domains and data elements that define the structure and characteristics of data fields. The document also covers technical settings such as delivery classes, data classes, buffering permissions, and foreign keys for establishing relationships between tables.

Uploaded by

gmbalaji
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
95 views9 pages

Abap Dictionary

The ABAP Dictionary (Tcode: SE11) is a central repository for managing data definitions in SAP systems, allowing for the creation of database tables, views, data types, and more. Key components include transparent, pooled, and cluster tables, as well as domains and data elements that define the structure and characteristics of data fields. The document also covers technical settings such as delivery classes, data classes, buffering permissions, and foreign keys for establishing relationships between tables.

Uploaded by

gmbalaji
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 9

ABAP DICTIONARY ( Tcode: SE11 )

ABAP Dictionary to create and manage data definitions (metadata). The ABAP
Dictionary permits a central description of all the data used in the system without
redundancies

The most important object types in the ABAP Dictionary are:

 DATABASE Tables

Tables are defined in the ABAP Dictionary independently of the database. From
this table definition follows the creation of a table with the same structure in the
underlying database.

 Views

Views are logical views of more than one table. The structure of the view is
defined in the ABAP Dictionary. A view of the database can then be created from
this structure.

 Data Type
 Type Group

The structure of a type can be defined globally in ABAP programs. Changes to a


type automatically take effect in all the programs using the type.

 Lock objects

These objects are used to synchronize access to the same data by more than one
user. Function modules that can be used in application programs are generated
from the definition of a lock object in the ABAP Dictionary.

 Domains

Different fields having the same technical type can be combined in domains. A
domain defines the value range of all table fields and structure components that
refer to this domain.

 Search Help
DATABASE TABLE

Tables can be defined independently of the database in the ABAP Dictionary. The
fields of the table are defined with their (database-independent) data types and
lengths.

When the table is activated, the system creates a physical table definition in the
database for the table definition stored in the ABAP Dictionary. The system
translates the table definition from the ABAP Dictionary to a definition of the
particular database. You can see these relations between the ABAP Dictionary and
the database in the following figure.

Types of Database Table

 Transparent Table
 Pooled Table
 Cluster Table

Transparent Table

R3 Table

One to one relationship


DB Table

Both table will have same table name, same no of fields and same field name.

Pooled Table

R3 R3 R3

Many to One relationship


DB
Table-Pool
Each table will have different table name, different no of fields, different field
name.

Each table may or may not have relationship

Cluster Table

R3 R3 R3

Many to One relationship


DB
Table-Cluster

Each table will have different table name,


different no of fields, different field name.

Each table will have relationship

Note: by default we create only Transparent Table.

You must define the following for a table field in the ABAP Dictionary:

 Field name - The field name can have a maximum of 16 places and can
contain letters, digits and underscores. The field name must begin with a
letter.
 Key flag - Determines whether the field belongs to the table key.
 Initial Value Indicator - Set this indicator if a field must have an initial
value.
 Field type - Data type of the field in the ABAP Dictionary.
 Field length - Determines the number of valid places in the field.
 Decimal places - The number of places after the decimal point, specifying
numeric data types.
 Short description - Short text describing the meaning of the field.

To create table
 Top down Approach
 Bottom to top Approach

DOMAIN DATA ELEMENT FIELD

Domain: It describes the technical characteristics of the field like data type and
length. Fixed values and intervals can be specified.

Data Element: It describes the semantic characteristic of field like help document
and field label.

Domain and Data Element are reusable object

Delivery class

The delivery class controls the transport of table data when installing or upgrading,
in a client copy and when transporting between customer systems. The delivery
class is also used in the extended table maintenance.

There are the following delivery classes:

A: Application table (master and transaction data).

C: Customer table, data is maintained by the customer only.

Application table should be Client-Dependent table.

To make a table as Client-dependent, give first field of the table as MANDT


and its data element is MANDT, it must be primary key.

Data class in technical settings

The data class defines the physical area of the database (for ORACLE the
TABLESPACE) in which your table is logically stored. If you choose a data class
correctly, your table will automatically be assigned to the correct area when it is
created on the database.

The most important data classes are (other than the system data):

 APPL0 Master data

 APPL1 Transaction data

 APPL2 Organizational and customizing data

Master data is data which is frequently read, but rarely updated.

Transaction data is data which is frequently updated.

Organizational und customizing data is data which is defined when the system is
initialized and then rarely changed.

There are two more data classes available, USR and USR1. These are reserved for
user developments. The tables assigned to these data classes are stored in a
tablespace for user developments.

Note:The data class only has an effect on table storage for the database systems
ORACLE and INFORMIX.

Buffering Permission

You must define whether and how a table is buffered in the technical settings for
the table. There are three possibilities here:

 Buffering not allowed:

Table buffering is not allowed. You use this option when, for example,
application programs always need the most recent data from the table or the table
is changed too frequently.

 Buffering allowed but switched off:


Buffering is allowed from the business and technical points of view.
Applications which access the table work correctly with and without table
buffering. Whether or not table buffering results in a gain in performance depends
on the table size and access profile of the table (frequency of the different types of
table access). Initially the table buffering is not activated because it is not possible
to know what these values are in the customer system. If table buffering would be
advantageous for the table size and access profile of the table, you can activate it in
the customer system at any time.

 Buffering switched on:

The table is buffered. In this case you must specify a buffering type.

Buffering Types

The buffering type defines which table records are loaded into the buffer of the
application server when a table record is accessed. The following buffering types
exist:

 Full buffering:

The system loads all the records of the table into the buffer when one record of
the table is accessed.

 Generic buffering:

When a record of the table is accessed, all the records having this record in the
generic key fields (part of the table key that is left-justified, identified by
specifying a number of key fields) are loaded into the buffer.

 Single-record buffering:

Only the records of a table that are really accessed are loaded into the buffer.
Foreign Keys

You use foreign keys to define relationships between tables in the ABAP
Dictionary, create value checks for input fields and link several tables in a view or
a lock object.

A candidate key is a column, or set of columns, in a table that can uniquely


identify any database record without referring to any other data. Each table may
have one or more candidate keys, but one candidate key is special, and it is called
the primary key.

Views

 Data about an application object can be distributed to several tables.


 By defining a view, you can define an application-dependent view that
combines this data.
 The structure of such a view is defined by specifying the tables and fields used
in the view.
 Fields that are not required can be hidden, thereby minimizing interfaces.
 A view can be used in ABAP programs for data selection.

It is an imaginary table, it does not have memory to store data.

Types of View Table

 Database views are implemented with an equivalent view of the database.


 Projection views are used to hide fields of a table (only projection).
 Help views can be used as a selection method in search helps.
 Maintenance views allow you to maintain the data distributed to several
tables for one application object at a time.
Database Views

Often several database tables contain the data about an application object. A
database view provides an application-specific view of such distributed data.

Database views are defined in the ABAP Dictionary. The system automatically
creates a database view in the underlying database when you activate the view.

It is used for join more than one table, only relationship table can be joined.

Projection Views

You use projection views to hide fields of a table. This can minimize interfaces.
For example, when you access the database, you read and write only the field
contents actually needed.

TYPE GROUP

It is type “T - TYPE-POOL” program, used for declaring global data types and
constants.

We can declare variable, structure and internal table. The type group name must be
used as prefix for the declaration of var, structure, internal table.

After that, you define data types using the statement TYPES. It was also possible
to define global constants using the CONSTANTS statement. All the names of
these data types and constants must begin with the name of the type group and an
underscore: pool_

These Type Group can be used as reference in any ABAP workbench objects.

In an ABAP program, you must declare a type group as follows before you can use
it:

TYPE-POOLS <pool>.
This statement allows you to use all the data types and constants defined in the
type group pool in your program. You can use several type groups in the same
program.
TYPE-POOL ZDIVS .

TYPES: ZDIVS_NAME(20) TYPE C.

TYPES: BEGIN OF ZDIVS_STR,


EMPNO(5) TYPE N,
NAME(20) TYPE C,
DOJ TYPE SY-DATUM,
SALARY TYPE P DECIMALS 2,
END OF ZDIVS_STR.

TYPES: ZDIVS_ITAB TYPE ZDIVS_STR OCCURS 0.

You might also like