Data Dictionary Interview Questions

DDIC Interview Questions

What are Primary Index and Secondary Index in DDIC?

Every database table has a primary index. The primary index is created automatically by the system when the table is activated. The primary index consists of the key fields of the table and is always unique.

Secondary indexes are created on table’s non-key fields. Creation of secondary index might be required if ABAP programs select statements frequently access the table using its non-key fields i.e. create secondary index on fields that are frequently used in the WHERE clause of SELECT statements. Also, to benefit from secondary index, it is required that the field order in WHERE clause of SELECT statement should match the index field order.

What is DDIC or ABAP Dictionary?

The ABAP Dictionary centrally describes and manages all the data definitions used in the system. The ABAP Dictionary is completely integrated in the ABAP Workbench. I.e All the other components of the Workbench can actively access the definitions stored in the ABAP Dictionary.

The ABAP Dictionary supports the definition of user-defined types (data elements, structures, and table types). You can also define the structure of database objects (tables, indexes, and views) in the ABAP Dictionary. These objects can be automatically created in the database with this definition.

What type of objects can be created in the ABAP Dictionary?

Tables

Views

Data Elements

Structures

Table Types

Type Groups Domains

Search Helps

Lock objects

Explain the Domain, Data element, and the advantages?

Domain: It is used to define the Technical attributes (Data Type and Length) and the value range (Fixed Values and Intervals ). A domain is assigned to a data element. All table fields or structure components that use this data element then have the value range defined by the domain.

Data Element: Data Element = Documentation (short text) + Domain (data type  + length)
Advantages : 1. Reusability of Data Type , length , Description .
2. To Maintain the relationship between the tables. The related fields from each table should have the common domain

What is Primary Key and the Rules regarding the Primary Key in table creation ?

Primary key is One or more than One Field Combination to Identify the record from the Corresponding Database Table Uniquely.

Rules :

Each Table Should have Primary Key.
It Should be Data Type CHAR.
It Should appear as the First Field (at the Beginning of the Table).

Can we have more than One primary key in the Same Database table ?

No. But We Can Have more that One Field Combination as Primary Key but not more than One Primary Key

Can we use the same APPEND Structure in more than one database table?

No.

Why and how to handle the Currency and Quantity Fields Differently in table Creation?

(IBM, CapGemini, Satyam)

Working with Currency(Amount) and Quantity fields:

When we are working with international customers and Vendors, if you provide only the Amount figure, i.e., 1000, but it is not enough, as it is not clear whether it is 1000 INR, 1000 USD, 1000 EUR, 1000 MYR, etc. So you have to always provide the currency key(INR, USD, etc) when we are working with Amounts.

Similarly, when we are working with Quantity, we have to provide Units of the quantity.

Note: When the Amount Fields are created by using Data type CURR and the Quantity Fields by using QUAN. Then only the system expects Currency Key(CUKY) as a reference for Amount and Units Key (UNIT) as a reference for Quantity. This is a must to create a table with Currency and Quantity fields

Field NameData TypeReference Data type
AMOUNTCURRCUKY
QUANTITYQUANUNIT

Note: CURR and CUKY Fields Should be Linked in the Database, and Similarly, QUAN and UNIT Fields.

Explain the Foreign Key, the Importance of Foreign Key, Rules to Define the Foreign Key?

Definition: It is a field in one table (Foreign key table) that is connected to another table (Check table) via Foreign Key relationship and is to validate the data being entered in one table (Foreign key table) with a valid set of values from another table (Check table). 

Technical Requirements to create a Foreign Key:-

  1. The Domain names of the field in the Foreign Key table and for the field in the Check table should be same.
  2. The field in he check table should be Primary Key.

Explain the INDEX in DDIC?

INDEX: We can search a table for data records that satisfy certain search criteria faster using an index.

Indexing can be considered a copy of a database table that has been reduced to certain fields.This copy is always in sorted form. Sorting provides faster access to the data records of the table, for example using a binary search. The index also

contains a pointer to the corresponding record of the actual table so that the fields not contained in the index can also be read.

The primary index is distinguished from the secondary indexes of a table. The primary index contains the key fields of the table and a pointer to the non-key fields of the table.

The primary index is created automatically when the table is created in the database.

Secondary INDEX:

Secondary INDEXes are the Custom(Further) INDEXs on a table in the ABAP Dictionary.

This is necessary if the table is frequently accessed in a way that does not take advantage of the sorting of the primary index for the access.

Note: All the counters of carriers at a certain airport are often  searched for flight bookings. The airport ID is used to search for counters for such an access. Sorting the primary index is of no use in speeding up this access. Since table SCOUNTER has a large number of entries, a secondary index on the field AIRPORT (ID of the airport) must be create to support  access using the airport ID.

To Create the secondary INDEX,

Execute SE11, Enter the database table name and press Display -> Indexes -> Create Enter index name.

Choose Maintain logon language.

Enter short description and index fields.

Save , Check and Activate .

What is Table Maintenance Generator ?

(Robert Bosch ,IBM,CapGemini,Satyam,Patni,TCS)

The Table Maintenance Generator is used to create table maintenance program to add, modify or delete records in the database table. This can be accessed using transaction SM30 or SE54 or in SEII using the menu Utilities->Table Maintenance Generator

What is One step, two step in Table Maintenance Generator?

This specifies the screens to be created in the Table Maintenance Program.

Single Step: Only overview screen is created i.e. the Table Maintenance Program will have only one screen where you can add, delete or edit records.

Two Step: Two screen namely the overview screen and single screen are created. The user can see the Key fields in the first screen and can further go on to edit further details.

What is Type Group ?

We can define data type in a type group in the ABAP/4 Dictionary instead of defining them within an ABAP/4 program.

  • The type group name in the ABAP/4 Dictonary has a maximum of 5 characters. The Data Type name within type group < typepool> must begin with <typepool> followed by an underscore.

Note: Up to 4.6C Version, We Can create the TYPE Group SE80>Data Dictionary But not from SE11. Where as from 4.7EE Version we can still create it through SE11 itself.

EX: SLIS is created by SAP to work with all the Datatypes required to Work with ALV.

The types in a type group must be declared in ABAP/4 programs with the TYPE-POOLS command to access the DATA types from the TYPE-GROUP.

What is Search Help and types of Search Helps?

Elementary search help is for F4 help and collective search help is the collection of elementary search helps.

Elementary search helps : defines a search path where we will define the table from which the data has to be read and the selection criteria. Through import and export parameters.

Used when we gets the data from a single table.

Collective search helps:- Combination of elementary search Helps. When we need to fetch data based on multiple selection criteria’s from More than one tables.

Ex : Search the Customer BY General Data, BY Company Code, BY City etc..

Each One is Elementary Search Help and the Combination is Collective Search Help.

Explain the below Terms?

  1. Table Maintenance
  2. Data Class
  3. Delivery Class
  4. Size Category

Table Maintenance : It allows the user to maintain the data manually.

Data Class: The data class determination which tablespace (Physical area) the table is stored when it is created in the database.

Size Category: The size category described the probable space requirement of the table in the database.

Delivery Class: It Defines the type of the data that is going to be stored and also it defines the owner of the Table and also the delivery class controls the transport of table data for installation upgrade, client copy and when transporting between customer systems.

What is View and Explain the types of views?(SAP Labs,Robert Bosch ,IBM)

A view is a logical view on one or more tables. A view on one or more tables i.e, the data from a view is not actually physically stored instead being derived from one or more tables. A view can be used to summarize data which is distributed among several tables

Types Of Views :

  • Projection View – Just retrives some fields from a single table
  • Help view – This is used for search help
  • Database view – This is inner join view of one or more tables
  • Maintenance view  – Helps in creating maintaining data of the application object, The data can be distributed among several tables.

What are the different Types of Data Dictionary Tables?

Transparent Table:- It is used application data such as Master and Transactional Data. We always create Transparent tables only.

There is a One to One relationship i.e. for the table in DDIC another table with the same structure and the same name and the same fields will be created in the original data base.

Pooled Tables and Table Pools:.

It should be used exclusively for storing internal control information (screen sequences, program parameters, temporary data, continuous texts such as documentation).

The data from several different pooled tables can be stored together in a table pool.

This is Many to One relationship i.e. for many pooled tables in DDIC only one Data base table will be created in the Data Base.

Cluster Table and Table Cluster:-

It should be used exclusively for storing internal control information (screen sequences, program parameters, temporary data. Continuous texts such as documentation).

The data from several different cluster tables can be stored together in a table clusters.

This is Many to One relationship i.e. for many cluster table in DDIC only one Data base table will be created in the Database.

Note:- All the Tables in the Cluster Tables should have a common Primary Key.

In order to create a custom (user defined) database table there are TWO types of approaches.

What is View and Explain the types of views?(SAP Labs,Robert Bosch ,IBM)

Maximum. But not 9, where all the other Materials and Some Websites Says it is 9. (Try yourself Including the Structures in the Custom Table).

What are two methods of modifying SAP standard tables to Add New Fields ? (KEANE,Wipro,SAPLabs,RobertBosch,IBM,CapGemin,Satyam,Patni,TCS)

Append Structures and Customizing Includes.

Append Structure : It is to be Created for the Table for which the additional Fields should be added.

Custom INCLUDE : SAP itself ADD the Cl Include In the Table, Which Can be

Created by Simply Double Click on it. We Can add the Additional Fields to the Standard Table, Only When SAP Provides CI Include in the Custom Table.

Note: CI Includes are available in most of HR Tables.

Table PA0021

1f a table that is to be extended contains a long field, we cannot use append structures why?

Note : Long fields in a table must always be located in the end.

If a table has an append structure, if it has a Long Field , Make Sure that the Long Field is Last Field in the APPEND Structure . So that we can APPEND the Structure.

Note : When another APPEND structed is Created, it shoud be APPENDed after the previous APPEND, i.e we are going to add new fields after the Long Field, where we are violating the rule that the Long Field should be at the end of the Table.

What are conversion routines/Exits?

(KEANE,Wipro,SAPLabs,RobertBosch, IBM,CapGemin, Satyam,Patni,TCS)

Non-standard conversions from display format to sap internal format and vice-versa are implemented with so called conversion routines.

Ex: ALPHA

CONVERSION EXIT ALPHA INPUT Conversion exit ALPHA, external->internal

CONVERSION EXIT ALPHA OUTPUT Conversion exit ALPHA, internal->external

What is Locking, Lock Objects, and FMs?

(RobertBosch,IBM, CapGemini, Satyam,Patni,TCS,Infosys)

Lock 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

Note 1: Activating a lock object in the ABAP Dictionary automatically creates function modules for setting the object name (ENQUEUE_<lock object name>) and (DEQUEUE_<lock object name>).

Note 2: The lock Object name should start with ‘E’.

What are the check tables and value tables?

The Check Table is the dependent table to which the relationship is defined using foreign keys. The contents of the check table field are shown in the input help for the referenced field.

The Value table is the table attached to a field at the domain level, where the entry to the field can be only from the value table. They are not used in the input help.

Note: The Value table is the default check table.

Which field differentiates a table from client–dependent and client–independent?

The MANDT field of the table specifies whether the client is independent or not.

What is the difference between Database tables and Views?

The Table has a physical storage of data, whereas views do not have physical storage of data.

The view is derived from one or more tables, which are created only with the required fields from the database table(s). It can also be created with table inner joins and specifying conditions for data retrieval.

Can I use all the views in the ABAP program?

No. You can use only the projection view or the database view in your ABAP program.

How do you activate the database (Delete or change Field After having data of it) table after making changes to it?

(Infosys, Accenture, RobertBosch, IBM, CapGemini, Satyam, Patni, TCS)

After making changes to the table in DDIC to reflect the changes in the actual Database, go to transaction SE14 and choose Edit, and then choose Activate and Adjust Database. (OR) You can directly activate it from the SEII -> Utilities ->Database Utility->Activate and Adjust Database

Which table are the programs, Tables, and Development Classes stored in?

(Infosys ,Accenture,RobertBosch,IBM,CapGemini,Satyam,Patni,TCS)

The programs are stored in the table TADIR, and the development class packages in TDEVC, Database Tables in DD02L and DD02T(Short Text)

When one creates new entries in the table, the field values are always in Uppercase.     

How do I get the data with mixed case?

The reason for this is that the Domain for the field in the table might have the Lowercase checkbox unchecked. Check the Lowercase checkbox to preserve the case of your data.

What are the Important Tables to store the definition in DDIC?

TableShort Text
DD02LSAP Tables
DD02TSAP Table Texts
DD01LDomains
DD01TDomain Texts
DD03LTable Fields
DD03TTexts for fields (language dependent)
DD04LData elements
DD04TData elements texts
DD05LForeign key fields

Scroll to Top