09 kaavian data dictionary
TRANSCRIPT
-
7/31/2019 09 Kaavian Data Dictionary
1/33
DATA DICTIONARY
Kaavian Systems02-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
2/33
Purpose
The ABAP Dictionary serves as the central description of data
used in R/3 system .
It Supports the creation and management of Metadata.
New or modified information is automatically provided for all the
system components.
It ensures data integrity, data consistency and data security.
Kaavian Systems 202-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
3/33
-
7/31/2019 09 Kaavian Data Dictionary
4/33
For Example You declare a variable in your program
DATA: MARA_TAB TYPE MARA.
Only structure MARA_TAB is declared in the program.
All the information about this structure, such as the field
names, data types and field lengths, are copied from table
MARA, which is defined in the ABAP Dictionary. This
information about table MARA is called from the ABAP
Dictionary when the program is generated.
Kaavian Systems 402-Sep-09
Integration in the ABAP workbench
-
7/31/2019 09 Kaavian Data Dictionary
5/33
Kaavian Systems 502-Sep-09
Object Types
-
7/31/2019 09 Kaavian Data Dictionary
6/33
Tables
Tables can be defined independently of the database in the
ABAP Dictionary.
The table definition is translated from the ABAP Dictionary to
a definition of the particular database.
When the table is activated, a physical table definition is
created in the database for the table definition stored in the
ABAP Dictionary.
Kaavian Systems 602-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
7/33
Reference Fields and Reference Tables
You must specify a reference table for fields containing
quantities (data type QUAN) or currency amounts (data type
CURR).
This reference table must contain a field with the format for thecurrency key (data type CUKY) or unit of measure (data type
UNIT). This field is called the reference field of the output
field. The reference field can also reside in the table itself.
A field is only assigned to the reference field at program
runtime.
Kaavian Systems 702-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
8/33
Components of Tables
Table fields : Define the field names and data types of the fields
contained in the table
Foreign keys : Define the relationships between the table and
other tables.
Technical settings : Controls how the table should be created in
the database.
Indexes : Speeds up data selection, secondary indexes can becreated for the table
Kaavian Systems 802-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
9/33
Include structure
In addition to listing the individual fields, you can also include the
fields of another structure in tables .
Only flat structures can be included.
Include structures can be included at any line of the field
definitions of the table.
The components of the structure now becomes the component of
the table.
Kaavian Systems 902-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
10/33
Append structures
An append structure is a structure that is assigned to exactly one
table or structure.
It is used to give enhancements to the already existing SAP tables
by adding fields at the last.
An append structure could be added only at the last of the table .
Kaavian Systems 1002-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
11/33
Foreign keys
Foreign keys are used to maintain the referential Integrity between
dependant tables.
Foreign keys can also be used to link several tables in a view or a
lock object.
The dependant table is called foreign key table and the referenced
table is called the check table.
Kaavian Systems 1102-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
12/33
Technical settings
The technical settings of a table define how the table will be
handled when it is created in the database .
The most important parameters are
Data class : Defines the Tablespace.
Size category : Defines the size of the extents created for the table.
The Buffering type should be specified if the buffering is switched
on.
Kaavian Systems 1202-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
13/33
Buffering
Full buffering
All the records of the table are loaded 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 are loaded into the buffer.
Single-record buffering
Only the records of a table that are really accessed are loaded into
the buffer.
Kaavian Systems 1302-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
14/33
Indexes
Indexes are used for faster Access in the Database.
Two types of indexes:
Primary indexes
Secondary indexes
Primary indexes are created automatically from the key fields
of the table.
Secondary indexes are created by the user specifying the
fields in the table.
Kaavian Systems1402-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
15/33
Views
A view is used to project and select the fields from more than
one table as a single structure.
View does not store the data physically of its own.
Kaavian Systems 1502-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
16/33
Types of Views
Database Views
Projection Views
Help Views
Maintenance Views
Kaavian Systems 1602-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
17/33
Database Views
Database Views are used to project the particular fields from the
different tables using conditions.
A corresponding view is created in the database and hence the
technical setting should be maintained.
The foreign key relationship is not required for joining.
Always inner join is performed.
Kaavian Systems 1702-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
18/33
Projection Views
It is used to project only the particular fields of a table.
The selection of records is not possible.
The maintenance status could be set to read and change the
records.
Kaavian Systems 1802-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
19/33
Help Views
A help view is created if a view with outer join is needed as
selection method of a search help.
Foreign key relationship should exist between the tables.
It always implements an outer join.
Kaavian Systems 1902-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
20/33
Maintenance View
Its used for maintaining complex database objects as a single
logical unit.
It implements outer join.
Foreign key relationship should exist between the tables.
Insertion and deletion is possible in the view.
SM30 is the transaction used for maintaining it.
Kaavian Systems 2002-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
21/33
Types
Data Elements
Structure
Table types
Kaavian Systems 2102-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
22/33
Data elements
Data elements describes an elementary data type.
The elementary data type could be either a domain or built in
data types.
Its used to maintain the field labels.
Its used to describe the documentation for the particular data
element. (F1 Help)
Kaavian Systems 2202-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
23/33
Structure
A structure is a sequence of any other data types from the
ABAP Dictionary, that is, data elements, structures, table
types, or database tables.
When you create a structure in the ABAP Dictionary, each
component must have a name and a data type.
In an ABAP program, you can use theTYPE addition to refer
directly to a structure.
Kaavian Systems 2302-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
24/33
Table type
Table types are construction blueprints for internal tables that are
stored in the ABAP Dictionary
When you create a table type in the ABAP Dictionary, you specify
the line type, access type, and key.
The line type can be any data type from the ABAP Dictionary, that
is, a data element, a structure, a table type, or the type of a
database table.
In an ABAP program, you can use the TYPE addition to refer
directly to a table type.
Kaavian Systems 2402-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
25/33
Domain
A domain defines a value range for a data element.
Fields or components that refer to the same domain are also
changed when the domain is changed which ensures
consistency.
A conversion routine can be assigned to a domain. This
conversion routine converts values from display format to
internal format for the fields or components that refer to this
domain.
Kaavian Systems 2502-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
26/33
Conversion routines
The following function modules are assigned to conversion routine
xxxxx:
conversion_exit_xxxxx_input
conversion_exit_xxxxx_output
conversion_exit_xxxxx_input is used to convert to the form stored
in the database.
conversion_exit_xxxxx_output is used to convert the format stored
in the database to the display format.
Kaavian Systems 2602-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
27/33
Search helps
Search helps are used to provide the Input Help for the fields in the
screen.
There are two types:
- Elementary search help
- Collective Search help
Kaavian Systems 2702-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
28/33
Elementary search help (example)
Kaavian Systems 2802-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
29/33
Collective Search Help
A collective search help combines several elementary search helps.
You only have to specify the search helps that are to be combined
in the collective search help.
Kaavian Systems 2902-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
30/33
Collective Search Help (Example)
Kaavian Systems 3002-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
31/33
Lock Objects
Lock object is created and maintained by data dictionary
When two users simultaneously attempt to access the same data
record, this is synchronized by a lock mechanism
Lock Mode
E Exclusive
S Shared
X Exclusive, But not Cumulative
Kaavian Systems 3102-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
32/33
Transactions
SE11 - ABAP Dictionary
SE13 - Dictionary Technical settings
SE14 - Database Utility
SE15 - Object Navigator ( Repository Information System )
SE16 - Data Browser
Kaavian Systems 3202-Sep-09
-
7/31/2019 09 Kaavian Data Dictionary
33/33
Reference
The learning material contained in this PowerPoint Presentation is prepared with the
help of http://help.sap.com/ and sap press book. All rights reserved by SAP AG.
Unless otherwise specifically stated, this learning material is intended for the solepurpose of class room session, internal use and for knowledge transfer to the
Consultants.
However, for detailed information on this learning material, http://help.sap.com /sap press book may be referred.
Kaavian is not liable for any legal liability or responsibility for the accuracy,
completeness or usefulness of any information disclosed in these learning materials.
No portion of the learning materials shall be modified, reproduced or transmitted in
any form by any means, whether by electronic, photocopier or otherwise without thewritten permission of Kaavian. In no event shall Kaavian be liable for any damage
whatsoever resulting in any action arising in connection with the use of learning
material.
02-Sep-09 Kaavian Systems 33