0% found this document useful (0 votes)
2 views

2. Data Dicionary

The ABAP data dictionary is a central repository that defines the logical structures of data objects used in application development, detailing their attributes and relationships. It performs functions such as managing data definitions, ensuring data consistency, and supporting software development. Key components include tables, domains, data elements, and foreign keys, with various methods for creating and managing these elements to optimize database interactions.

Uploaded by

ksklb8
Copyright
© © All Rights Reserved
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views

2. Data Dicionary

The ABAP data dictionary is a central repository that defines the logical structures of data objects used in application development, detailing their attributes and relationships. It performs functions such as managing data definitions, ensuring data consistency, and supporting software development. Key components include tables, domains, data elements, and foreign keys, with various methods for creating and managing these elements to optimize database interactions.

Uploaded by

ksklb8
Copyright
© © All Rights Reserved
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 18

Data Dictionary

What is an ABAP data dictionary?


ABAP 4 data dictionary describes the logical structures of the objects used in application development and shows how
they are mapped to the underlying relational database in tables/views. It is a central source of data in a data
management system. It has details about:
 What data is contained?
 What are the attributes of the data?
 What is the relationship existing between the various data elements?

What functions does a data dictionary perform?


In a data management system, the principal functions performed by the data dictionary are:
 Management of data definitions
 Logical, Complete and Consistent Data
 Provision of information for evaluation
 Support for software development
 Support form documentation
 Ensuring that the data definitions are flexible and up-to-date.

What are the features of ABAP/4 Dictionary?


The most important features are:
 Integrated to ABAP/4 Development Workbench
 Active in the runtime environment

What are the basic objects of the ABAP Dictionary?


Tables, Domains, Data elements, Structures, Foreign Keys.

What are table fields defined by in SAP R/3?


Data Elements and Domains.

What information does the SAP data dictionary store?


Metadata.

A field is not a dictionary object. (True/False)


True.

What are the ways of creating Tables?


 Top-down approach: In this approach, first fields are defined and later domain and data element are defined.
 Bottom-up approach: In this approach, first domain and data element are defined and later fields are defined.

What is the step by step process to create a table in data dictionary?


Selecting the table fields -> maintaining foreign keys -> creating secondary indexes (optional) -> maintaining technical
settings -> activating a table.

What is the significance of Technical settings (specified while creating a table in the data dictionary)?
By specifying technical settings we can control how database tables are created in the database. The technical settings
allow us to:
 Optimize storage space requirements
 Table access behavior
 Buffering required
 Changes to entries logged

What are Fields, Data Element and Domain?


Fields: where the data is stored.
Data Element: Data Element is used to describe the semantic definition of the table fields like description the field.
Data element describes how a field can be displayed to end-user and the role played by a domain in a technical
context.
Domain: Domain is the central object for describing the technical characteristics of an attribute of a business objects. It
describes the value range of the field.

What do you define in the Data element and Domain?


For Data Element: The information includes the field's representation on the screen in the form of FIELD TEXTS,
COLUMN CAPTIONS in list outputs of the table contents and the format of the output via PARAMETER IDS and Online
field documentation.
For Domain: Data Type, Field Length and the allowed data values are defined.

What are the two ways for restricting the value range for a domain?
 By specifying fixed values: The value range of domain can be restricted by defining fixed values. If fixed values are
defined for a domain, these are used in the input check in screen templates. To create or maintain an explicit list of
valid values, use the menu path Go to → Fixed Values on the Change Domain screen in the ABAP Dictionary. Explicit
values are used when the list of valid values is not likely to change over time. For example, if a domain were meant
to contain the names of the months of the year, it would be possible to explicitly list “JANUARY” through
‘DECEMBER’ as the allowed values (note that this would not work well in a multi-language environment).
 By stipulating a value table: Valid values for a domain can also be specified by reference to a value table. When this
is done, the records in the value table specify the valid values for the domain. In order to specify a value table for a
domain, one of the key fields of that table must point to that domain. That field is the one that determines the valid
values for the domain. A value table is used when the list of valid values may change over time. For example, a car
maker may want to use a value table to list the valid colors for certain car models. As new colors are developed, the
value table could be updated without changing the domain itself.

What are the benefits of allowed value range?


 By defining valid values for a domain, automatic validation is provided for any fields that point to that domain. This
includes validation at the ABAP Dictionary level (if a program tries to insert invalid data, an error will occur) as well
as at the screen level (users will not be permitted to enter invalid data).
 Additionally, users can obtain a list of possible entries (for fields pointing to domains with allowed values) by
pressing function key F4.

Can you define a field without a data element? We can do this with predefine data type…divvis
Yes. If you want to specify no data element and therefore no domain for a field, you can enter data type and field length
and a short text directly in the table maintenance. In SE11 one option is available above the fields strip - Data element/
direct type.

Can you create a table with fields not referring to data elements?
Yes. e.g. - ITAB LIKE SPFLI. Here we are referring to a data object (SPFLI), not data element.

Can you define a field without referring to a domain?


Yes, we can create dictionary tables without referring to a domain. This is done by clicking on "Built in type" button
during table creation.

Can you delete a domain, which is being used by data elements?


No.

Can you delete data element which is being used by table fields.
No.

Can a domain, assigned to a data element be changed?


Yes. We can do so by just overwriting the entry in the field domain.

How do you document ABAP/4 programs? Do you use program documentation menu option?
You can also enter documentation for the data element. Choose Go to ->Documentation. Or press F9. The text that you
enter here will be displayed when you press F1 on the field. Under Extra -> DE Supplement Docu., you can specify some
additional documentation like the possible cause of error, what should be done in case of error etc. You can also change
the document status with transaction SE61.

The attributes ___________, _____________ and ___________ are used for management of ABAP/4 program.
Type, Application and Class.

ABAP/4 Dictionary contains the _______________ (Logical/Physical) definition of the table.


Logical.

What is foreign key relationship?


A foreign key provides a link between two tables T1 and T2. Both the tables should have the same field names existing
in them. In table T1 there is a reference to the primary key of table T2. In T1, the foreign key fields are assigned to the
primary key fields of T2. The table to be checked i.e. Table T1 is called the foreign key table (dependent table) and
table T2 is called the check table (referenced table).
Like T000 for client, T001W for company codes (WERKS), tcurc for currency. When we write code like
PARAMETER V_WERKS LIKE MARC-WERKS OBLIGATORY VALUE CHECK
The value we entered will be cross checked with the table T001W for existence.
The fields from the two tables, which are paired to form the foreign key relationship, should be of the same data type
and length. In other word one foreign key from one table should correspond with the primary key of the other table. A
field defined as foreign key in one table should be defined as Primary key in another table.

What is Cardinality in foreign key relationship?


While defining foreign key relationship cardinality has to be specified. The cardinality (n:m) describes the foreign key
relationship with regard to the number of possible dependent records (records of the foreign key table) or referenced
records (records of the check table).
The left side (n) of the cardinality is defined as follows:
 n=1: There is exactly one record assigned to the check table for each record of the foreign key table.
 n=C: The foreign key table may contain records which do not correspond to any record of the check table because
the foreign key field is empty. This can occur for example if the field of the foreign key table is optional, in which
case it does not have to be filled.
The right side (m) of the cardinality is defined as follows:
 m=1: There is exactly one dependent record for each record of the check table.
 m=C: There is at most one dependent record for each record of the check table.
 m=N: There is at least one dependent record for each record of the check table.
 m=CN: There may be any number of dependent records for each record of the check table.
For cardinality one out of domain or data element should be the same for tables. In order to have a foreign key
relationship established in SAP, the fields involved must share the same domain and that domain must have a value
table specified.

What is the difference between a Value table and a Check table?


 Value table contains set of allowed values attached to a domain; Check table is that which is referenced by a foreign
key.
 A check table is either identical to a value table, or is another table containing a subset of the records in a value
table.
 The Value Table is optional in the foreign key definition. Foreign Key definitions must always have a Check Table
assigned.
 Value table will be at domain level checking; Check table will be at field level checking.
In many cases, the value table and the check table will be the same - Explain that.
For example, suppose a foreign key relationship was established between an ORDERS table and a PRODUCTS table in
order to ensure that orders contained valid product numbers. In this case, it is likely that the value table and the check
table would both be the PRODUCTS table.

Sometimes check table is another table containing a subset of the records in a value table – Explain that.
For example, suppose a telephone company stores general customer information in the CUSTOMERS table and stores
specialized information about business customers in the BUSINESS_CUSTOMERS table. Suppose that there was also a
BUSINESS_OWNERS table that listed the owners of all business customers. The BUSINESS_OWNERS table might consist
of two fields: Customer ID and the name of each individual owner. In this case, we would establish a foreign key
relationship between the BUSINESS_OWNERS table and the BUSINESS_CUSTOMERS table. The value table for the
customer ID field in the BUSINESS_OWNERS table would be the CUSTOMERS table, but the check table would be the
BUSINESS_CUSTOMERS table. The foreign key table would be the BUSINESS_OWNERS table.

What is Partial Foreign Key Relationship?


When creating a partial foreign key, certain fields are flagged as generic. These fields are ignored by the system when
validating records that are inserted into the foreign key table.
For example, suppose that we were tracking information about new courses that were under development in an
YNEWCRS table. This table would have faculty and course number as the primary key. However, in this table, we would
not want to validate the course number against the YCOURSES table, because by definition the new courses are not yet
in the YCOURSES table. In this case, we might use a partial foreign key from YNEWCRS to YCOURSES and flag the course
number field as generic. In other words, the table YNEWCRS would be forced to have valid values in the faculty field, but
we could enter any course number we wanted.
Note: If additional fields are added to the primary key of a check table, the new fields are automatically flagged as
generic in any previously existing foreign keys.

What is Constant Foreign Key Relationship?


When creating a constant foreign key, certain fields are assigned a literal value. Only records in the check table with that
value in the corresponding field are used to determine whether records in the foreign key table are valid.
For example, suppose there was a table YBIOCRS that contained specific information about biology courses. The primary
key of this table would be course number only (it would already be understood that the courses were biology courses).
In this case, we would want to validate the course number against the YCOURSES table, but we would only want biology
course numbers to be valid. That is, if there was a course “English 402” but no course “Biology 402”, we would not want
402 to be a valid entry in table YBIOCRS. To accomplish this, we could establish a foreign key from YBIOCRS to YCOURSES
with the constant value “BIO” in the faculty field.
Note: Assigning a constant value to a field has the effect of restricting the values that are permissible for the other
foreign key fields in the foreign key table. Validation is actually turned off for the field that is assigned the constant
value. For example, if we changed the above example so that the table YBIOCRS did have a faculty field, it would be
possible to enter any value in that field.

It is possible to combine the use of partial and constant foreign keys within the same foreign key relationship. (True /
False)
True.

What is the meaning of ABAP/4 Editor integrated with ABAP data dictionary?
Data dictionary is kind of interface for editor to retrieve data from database level to presentation area. It’s a Meta
data.

What are the general naming conventions of ABAP programs?


ABAP programs should start with Y or Z. Y or Z report refer to customized ABAP programs written for all SAP modules.

Can we create an ABAP program without using Y or Z?


No, this is because all non Y or Z programs are standard SAP programs.
Name a few system global variables you can use in ABAP programs?
SY-SUBRC, SY-DBCNT, SY-LILLI, SY-DATUM, SY-UZEIT, SY-UCOMM, SY-TABIX, etc.

What is a Table attribute?


The table attributes determine who is responsible for maintaining a table and which types of access are allowed for the
table. The most important table attributes are:
 Delivery class.
 Table view maintenance (allowed/not allowed/allowed with restrictions).
 Activation type.

What is the significance of Delivery Class?


The significances of Delivery Class are:
 The delivery class controls the degree to which the SAP or the customer is responsible for table maintenance.
 Whether SAP provides the table with or without contents.
 Determines the table type.
 Determines how the table behaves when it is first installed, at upgrade, when it is transported, and when a client
copy is performed.

What are the possible Delivery Classes?


There are the following delivery classes:
 A: Application table (master and transaction data).
 C: Customer table, data is only maintained by the customer.
 L: Table for storing temporary data.
 G: Customer table, SAP may insert new data records but may not overwrite or delete existing ones.
 E: System table with its own namespace for customer entries. The customer namespace must be defined in table
TRESC.
 S: System table, data changes have the status of program changes.
 W: System table (e.g. table of the development environment) whose data is transported with its own transport
objects (e.g. R3TR PROG, R3TR TABL, etc.).

What are possible Table Buffering types?


 Full buffering (100%): first time the table is accessed, its entire contents are loaded in the table buffer. Either, whole
table or none of the table is located in the buffer (Tables up to 30 kb done in client dependent fully buffered tables).
 Generic buffering: In this case, you need to specify a generic key (some of the key fields) in the technical settings of
the table in the ABAP Dictionary. The table contents are then divided into generic areas. When you access data with
one of the generic keys, the whole generic area is loaded into the table buffer. Client-specific tables are often
buffered generically by client.
 Single record buffering: only single entries are read from the database and stored in the table buffer. Records
actually being accessed are loaded to buffers, large records where few records are accessed.

Which type of tables used this buffer?


 Tables that are read very frequently.
 Tables that are changed very infrequently.
 Relatively small tables (few lines, few columns, or short columns).
 Tables where delayed update is acceptable.

Only Transparent and Pooled table can be buffered. Buffering is not permitted for Cluster Tables. (True/False)
True.

When you read from buffered tables, what happens?


 An ABAP program requests data from a buffered table.
 The ABAP processor interprets the Open SQL statement. If the table is defined as a buffered table in the ABAP
Dictionary, the ABAP processor checks in the local buffer on the application server to see if the table (or part of it)
has already been buffered.
 If the table has not yet been buffered, the request is passed on to the database. If the data exists in the buffer, it is
sent to the program.
 The database server passes the data to the application server, which places it in the table buffer.
 The data is passed to the program.

Buffer gets clear after archiving. (True/False)


False.

Tables buffered by record reside in the single-record table buffer___________, fully and generically buffered tables
share the full/generic table buffer____________.
TABLP, TABL.

A table is buffered. By select statement I don’t want to get the data from table buffer. I want to get the data from
database. How?
If buffering is allowed for a table in the ABAP Dictionary, the SELECT statement always reads the data from the buffer in
the database interface of the current application server. To read data directly from the database table instead of from
the buffer, use the following:
SELECT... FROM <tables> BYPASSING BUFFER. ..
This addition guarantees that the data you read is the most up to date. However, as a rule, only data that does not
change frequently should be buffered, and using the buffer where appropriate improves performance. You should
therefore only use this option where really necessary.

What is spool buffer?


Spool buffer is the memory space which is allocated in DB level or OS level where all the data are stored in that buffer
area at the time giving prints. In another point of view we can say that all printing data's goes through this buffer
(memory). When it is created in DB level, then its size is restricted. Due to this there is a chance to fill up buffer area.

What is Activation?
During activation, the runtime object of aggregate object or tables is created. The runtime object is buffered so that the
application program can access it quickly. Runtime object has information about the following objects of table – domain,
data elements, field definition & table definition.

Is it possible to increase the number of key fields in transparent tables that are already active?
No, Key changes are not allowed.

What are Version catalog & Version Management functions?


One of the important features of Workbench Organizer is Version Management. This feature works for all the
development objects. Using the version management feature the users can compare and retrieve previous versions of
objects. Version management provides for comparisons, restore of previous versions, documentation of changes and
assistance in the adjustment of data after upgrading to a new release. With the release of a change request, version
maintenance is automatically recorded for each object. If an object in the system has been changed N times, it will have
N delta versions and one active version. To display version management - for ABAP, use transaction SE38 and for tables,
domains and data elements use SE11. The path to follow is Utilities -> Display version. Using version management the
users can view existing version for previously created ABAP code, make changes to the code, compare code versions and
restore original version of the code. The users will be restore previous versions without cut and paste steps of the past.
Version catalog list of all existing versions of an object:
 Revised version: produced when we edit an existing object.
 Active version: produced when we activate an object.
 Temporary version: produced when we copy the active version temporarily to the database with store version
functions.
 Historical version: created when 1) Correction is created, and 2) correction is released.
Version Management functions are:
 Canceling changes: reset revised version to active version.
 Storing changes: active version will be temporarily stored in version.
 Switching changes: switch between active and revised versions.

How can we set the tablespaces and extent sizes?


You can specify the extent sizes and the tablespaces (physical storage area in the database) in which a transparent table
is to be stored by setting the size category and data class.

What is a Size Category? How Many types of size categories and data classes are there?
The Size category describes the probable space requirement of the table in the database.
There are five size categories (0-4) and 11 data classes, only three of which are appropriate for application tables:
 APPL0 - Master data (data frequently accessed but rarely updated)
 APPL1 - Transaction data (data that is changed frequently)
 APPL2 - Organizational and customizing data (customizing data that is entered when system is configured and then
rarely changed).
The other two types are:
 USR
 USR1 – Intended for customer’s own developments.

Describe data classes.


The Data class determines in which tablespace, the table is stored when it is created in the database.
Master data: Master data is a collection of information about a person or an object, e.g. a cost object, vendor, or G/L
account. For example, a vendor master record contains not only general information such as the vendor’s name and
address, but also specific information, such as payment terms and delivery instructions. Generally for end users, master
data is reference data that you will look up and use, but is seldom changed.
Transaction data: Transactional data is data related to a single business event such as a purchase requisition or a
request for payment. When you create a requisition, for example, SAP creates an electronic document for that particular
transaction. SAP gives t0068e transaction a document number and adds the document to the transaction data that is
already in the system. Whenever you complete a transaction in SAP, that is, when you create, change, or print a
document in SAP, this document number appears at the bottom of the screen. It is the data which is often changed.
Organization data: It is a customizing data which is entered in the system when the system is configured and is then
rarely changed. For example, Country Code.
System data: It is the data which R/3 system needs for itself.

What are control tables?


The values specified for the size category and data class are mapped to database-specific values via control tables.

How many maximum numbers of fields can be there in a table?


Don't cross the total size of each record to 255 characters. Maximum we can have 216 fields in a table and maximum 16
key fields.

What is the client concept in SAP? What is the meaning of client independent?
There are two types of tables in R/3 database: client-dependent and client-independent. A table is client-dependent if
the first field is of type CLNT. The length will always be 3 and by convention, this field is always named MANDT. If the
first field is not of type CLNT, the table is client-independent.

Are programs client dependent?


Yes. Users can access these programs with appropriate client no.

How can I make a differentiation between dependent and independent data?


Client dependent or independent transfer requirements include client specific or cross client objects in the change
requests. Workbench objects like SAPscripts are client specific; some entries in customizing are client independent. If
you display the object list for one change request, and then for each object the object attributes, you will find the flag
client specific. If one object in the task list has this flag on, then that transport will be client dependent.

In the Data Dictionary, Tables can be defined independent of the underlying database. (True/False)
True.

CASE 1: there are two clients using one Application Server. Are programs and tables client-dependent/independent?
CASE 2: There are two clients using different Application Servers. Are programs and tables client-dependent /
independent?
 CASE 1: Programs are client-independent and Tables are client-dependent.
 CASE 2: Programs and Tables, both are Client-dependent.

What is Repository Info Systems?


It is a tool with which you can make data stored in the ABAP/4 Dictionary available.

What is CTS and what do you know about it?


The Change and Transport System (CTS) (SE09/SE10) is a tool that helps you to organize development projects in the
ABAP Workbench and in Customizing, and then transport the changes between the SAP Systems and clients in your
system landscape. This documentation provides you with an overview of how to manage changes with the CTS and
essential information on setting up your system and client landscape and deciding on a transport strategy. Read and
follow this documentation when planning your development project.

What is the function of the transport system and workbench organizer?


The function of the transport system and the Workbench Organizer is to manage any changes made to objects of the
ABAP/4 Development Workbench and to transport these changes between different SAP systems. Transport system
allows to transports the object from one SAP system to another (Development system to Production system). It allows
to over write or delete existing object in target system and import new objects to target systems. During development
work we start by opening a task (correction) to which we can assign new and changed objects. Once changes have been
made, transport new or changed objects to other SAP system by means of transport (Change) request.

What is the function of the correction system?


Correction system manages the internal system components like objects like only original version of the object exists. It
stores all changes made to the object, such as objects of the ABAP/4 Dictionary.

How can we access the correction and transport system?


Each time you create a new object or change an existing object in the ABAP/4 Dictionary, you branch automatically to
the Workbench Organizer or correction and transport system.

How to release an object?


To release an object - use SE10/SE09. There write your task no and use release button it will asks the other system
name.

What is the exact difference between Transaction Codes SE01, SE09 and SE10?
 SE01 is for creating Transport Request with extended view, for all type of transport request.
 SE09 is the transaction code for workbench organizer. Workbench organizer is the set of utilities for development
change management. All Development changes are tracked via Workbench organizer.
 SE10 is for Customizing organizer. Customizing organizer is the set of tools for customizing change management. All
customizing changes are tracked via customizing organizer.

How do you transfer request from Development instance to production or quality instance?
After the configuration is done by the consultant, he saves that configuration. System automatically generates one
request (in Version 4.7c and above). The entire configuration done in the development server is stored in this request.
To test this configuration, it should be transferred to quality server which is done by Basis consultants. Go to SE10, select
our request which you want to release to Basis consultants, then you will see one development request number and one
correction number. First click on correction number and the go to toolbar and click on the transfer request button (lorry
icon). That means now it’s ready to be released for basis consultants from development server to quality server. Then,
go to STMS (Sap Transport Management System), we find all the released requests by the consultants. Here, choose the
request and transfer it to quality. There the testing is performed to see whether the outcome result is met with
expected result or not. If the testing is successful, then in the similar process, Basis consultants transfer the
configuration to production server and a mail is send to end-user to tell him to use it. After using that configuration
running successfully end-user will send you the return mail stating that your configuration is working properly. Now
again you send the mail to concerned person (TL or PL) with the end-user's mail as attachment. Then they will close that
ticket.

Which objects are independent transport objects?


Domains, Data elements, Tables, Technical settings for tables, Secondary indexes for transparent tables, Structures,
Views, Match code objects, Match code IDs & Lock objects.

Which object/s is/are not independent transport objects?


Primary Index.

How can we transport the ztable along with data to Production system?
 It’s possible to transport the data along with the table definition, by setting the Delivery class ‘W’ appropriately
under the delivery and maintenance tab of SE11.
 Once you fill the table, these objects are to be manually added to a transport request.
 Double click the task, Give some short description, Enter R3TR in program ID & Object type as TABU, and then insert
the values to the task.

What is Bundling technique?


Wrapping of released request with the new Transport request is called Bundling.

What is a Logical Unit of Work (LUW)?


Time gap between business update.

What is a Development class?


Related objects from the ABAP/4 repository are assigned to the same development class. This enables you to correct
and transport related objects as a unit.

How to create own development class for storing the programs?


For 4.6C IDES, go to SE80 -> Edit Object -> Select Radio-button ‘Development Class’ -> Enter name, starting with Y or Z ->
Create or F5 -> Enter the Short text -> Save -> It Creates Your Development class -> For Creating your own Request
Number , Click on ‘Create Request’ ->fill up the Short Text -> Save. It will then automatically create your own Request
Number. After this your program can be saved under your own development Class.

Can we copy a Development Class to another Development Class with all the objects?
You can copy a development class, but you can't copy the objects of the class by utilities provided in ABAP workbench.
We can rename the development class name through utilities ->object directory entry.

What are local objects?


Local objects (Development class $TMP) are independent of correction and transport system.

What is transparent table?


There is a physical table on the database for each transparent table. The names of the physical tables and the logical
table definition in the ABAP/4 Dictionary correspond. All business and application data are stored in transparent tables.

Can a transparent table exist in data dictionary but not in the database physically?
No. Transparent tables do exist with the same structure both in the dictionary and as well as in the database, exactly
with the same data and fields. Only time, a transparent table (definition) may exist in the data dictionary and not in the
database, when, it is not activated.

SAP stores __________ data and ____________ exclusively in transparent tables.


Master, Transaction.

Name the 5 different table types in the SAP ABAP dictionary.


1. Transparent tables
2. Structures
3. Pool tables
4. Cluster tables
5. Views.

What are the difference between transparent tables and pooled tables?
Transparent tables: Transparent tables in the dictionary have a one-to-one relation with the table in database. Its
structure corresponds to single database field. Table in the database has the same name as in the dictionary, same
number of fields, and the fields have the same name as in the R3 table definition. Transparent table holds application
data. Both Open SQL and Native SQL can be used.
Pooled tables: Pooled tables in the dictionary have a many-to-one relation with the table in database. For one table in
the database there are many tables in the dictionary. The table in the database has a different name than in the table in
the data dictionary, it has different number of fields and field-names are different. Pooled table are stored in table pool
at the database level. A table pool is a database table with a special structure that enables the data of many R3 tables to
be stored in it. It can hold only pooled tables. One cannot use native SQL on these tables (only open SQL).They are not
manageable directly using database system tools.

What are differences between Cluster Table and Pooled Table?


Pooled tables can be used to store control data (e.g. screen sequences, program parameters or temporary data). Several
pooled tables can be combined to form a table pool. The table pool corresponds to a physical table on the database in
which all the records of the allocated pooled tables are stored.
Cluster tables contain continuous text, for example, documentation. Several cluster tables can be combined to form a
table cluster. Several logical lines of different tables are combined to form a physical record in this table type. This
permits object-by-object storage or object-by-object access. In order to combine tables in clusters, at least parts of the
keys must agree. Several cluster tables are stored in one corresponding table on the database.

What is the difference between a table pool & pooled tables?


A table pool (or pool) is used to combine several logical tables in the ABAP/4 Dictionary. The definition of a pool
consists of at least two key fields and a long argument field (VARDATA).
Pooled tables are logical tables which must be assigned to a table pool when they are defined. Pooled tables can be
used to store control data (such as screen sequences, program parameters or temporary data).

What is the difference between transparent and non-transparent database tables?


 Transparent tables have 1 - 1 cardinality between Data Dictionary and Database, and non-transparent (Cluster &
Pooled) tables have Many - 1 cardinality.
 Transparent table can be accessed with both Open & Native SQL statements where as Non-transparent can only be
accessed Open SQL.
 Transparent tables can store Table relevant data. Non-transparent tables can store system & application data
based on the transparent tables.
What is a table cluster?
A table cluster combines several logical tables in the ABAP/4 Dictionary. Several logical rows from different cluster tables
are brought together in a single physical record. The records from the cluster tables assigned to a cluster are thus stored
in a single common table in the database.

_________ contains continuous text.


Cluster Table.

How data is stored in Cluster table?


A cluster table contains data from multiple DDIC tables. It stores data as a name value pair (varkey, vardata). Each field
of cluster table behaves as tables which contains the no. of entries.

Give example of Pooled and Cluster tables.


 Pooled Table: T001, CDPOS etc.
 Cluster Table: BSEG

What are Data Clusters?


You can group any complex internal data objects of an ABAP/4 program together in data clusters and store them
temporarily in ABAP/4 memory or for longer periods in databases. You can store data clusters in special databases of the
ABAP/4 Dictionary. These databases are known as ABAP/4 cluster databases and have a predefined structure. Storing a
data cluster is specific to ABAP/4. Although you can also access cluster databases using SQL statements, only ABAP/4
statements are able to decode the structure of the stored data cluster.

What is Structure (INTTAB)?


INTTAB tables are field strings (structures) which do not hold data. Therefore, they are not mapped to the database and
have no underlying database tables. INTTAB tables must be activated just like TRANSP tables. However, no technical
settings are required and the Database Utility is not automatically invoked when you press the ‘Activation’ icon since
INTTAB tables do not exist in the database.
Structures can be used in multiple tables. They help avoid redundant field definitions throughout the system.
Structures can be nested up to nine levels and can contain a maximum of one table. They are similar to the copybook
function of other programming languages.
Structures are used for the interface definition between programs or between screens and programs. Structures can
contain data only during the run time of a program.

What is the advantage of structures and how do you use them in ABAP/4 programs?
 A structure is defined in the ABAP/4 Dictionary like a table and can be accessed from ABAP/4 programs. Any change
to the definition of the structure in the ABAP/4 Dictionary is automatically implemented in all programs.
 While data in tables is stored permanently in the database, structures contain data only during the runtime of a
program.
 Structures are used in ABAP/4 programs to transfer data between programs as it is globally defined. Structures are
used in particular for defining data at the interface between module pools and screens and for standardizing
parameters for function modules.

What is the difference between a structure and a table?


Structures are constructed the almost the same way as tables, the differences are:
 No database table is generated from structures.
 Table can store the data physically but a structure dose not store.
 Table can have primary key but a structure dose not have.
 Table can have the technical attribute but a structure dose not have.

Describe about type of a table or structure.


The table type determines how the logical table description defined in the ABAP/4 Dictionary is reproduced on the
database. There are the following table types:
 transparent table
 structure
 append structure
For internal purposes, such as storing control data or update texts, there are in addition the following table types:
 pooled table
 cluster table
 generated view structure

Groups of fields may be added to customer tables using ____________.


Substructures.

What is Substructure?
Substructures allow you to include fields from another table or structure in the table you are creating. Rather than
listing all of the fields you want a table or structure to contain, you can choose to include the fields from another table
or structure as a substructure. This allows you to avoid redundant field definitions in structures/tables as well as
maintain changes for these common fields in one structure/table.
A structure can only be included in its entirety and must be of table type INTTAB or TRANSP. Substructures can be
nested up to nine nesting levels are allowed. TRANSP table types can only exist once in a nested chain.
To include a substructure in a table - Type “.INCLUDE” for the Field Name field on the Table Change screen, then type in
the name of the structure/table in the “Data elem.” field. You can expand and collapse substructures in the table /
structure definition screens they are used. This is an alternative way to see what fields the substructure holds, rather
than double-clicking on the substructure name to navigate to its definition.

What is Include Structure?


Customizing includes are provided in SAP tables and structures to allow you to add fields to these structures/tables
without modifying the tables themselves.
Customizing includes are supplied empty by SAP and are filled in by the customer with the help of special customizing
transactions. These includes make it possible to extend (add fields to) tables without modifying the tables themselves
and without the risk of additions being overwritten during a Release Upgrade.
Names of customizing include start with ‘CI_’. If a table does not contain a customizing include, you can still make
additions by creating an Append structure. You cannot add your own ‘.INCLUDE CI_’ to an SAP table.

What is Append Structure?


Append structures allow you to add fields to SAP-provided structures and transparent tables that were not provided for
in the standard version. These are intended for additions not provided for in the standard version of SAP tables via
customizing includes. They are to be used with SAP transparent tables or structures, not with customer tables.
An Append structure is a structure assigned to exactly one table. However, a single table can have a number of append
structures. It is recommended to use only one append structure in a table.
When an append structure is activated, its assigned table is also activated with all of the append structure fields. When
a table including an append structure is activated, the append structure fields are found and added to the table.
Append structures cannot be deleted.
Append structures cannot be used with tables containing fields of data type VARC, LCHR, or LRAW because these data
types must be the last field in a table.
Use the Append structures … push-button in the table display screen to add fields to SAP tables. Fields contained in an
Append structure are added to the SAP tables when an upgrade is performed and the appropriate tables are activated.

What is the difference between a Substructure and an Append Structure?


The difference between a Substructure and an Append Structure is:
 In case of a substructure, the reference originates in the table itself, in the form of a statement include... .
 In case of an append structure, the table itself remains unchanged and the reference originates in the append
structure.

What are the two methods of modifying SAP standard tables?


Append Structures and Customizing Includes.

Can we include customizing include or an append structure with Pooled or Cluster tables?
No.

What is the maximum number of structures that can be included in a table or structure?
9 structures.

To how many tables can an append structure be assigned?


One.

Is it possible to delete the append structure in a table?


No.

The amount of memory associated with a data type is ___________


ZERO.

The data object does not occupy any space in memory. (TRUE / FALSE).
FALSE.

Field strings are also called as ______________.


Records or Structures.

What are indexes?


Indexes are described as a copy of a database table reduced to specific fields. This data exists in sorted form. This
sorting form eases fast access to the field of the tables. In order that other fields are also read, a pointer to the
associated record of the actual table is included in the index. The indexes are activated along with the table and are
created automatically with it in the database.

What is primary index & secondary index?


The primary index contains key fields of a table and a pointer to non-key fields of the table. The primary index is created
automatically when a table is created in database and moreover you can further define reference to the primary index
which is known as Secondary index.

How many indexes can be created for a table?


9.

What are the layers of data description in R/3?


 The External layer: The external layer is the plane at which the user sees and interacts with the data, that is, the
data format in the user interface. This data Format is independent of the database system used.
 The ABAP/4 layer: The ABAP/4 layer describes the data formats used by the ABAP/4 processor.
 The Database layer: The database layer describes the data formats used in the database.

What are the Data types of the external layer?


External data types are the data types into which the Loader can convert internal database data types when it unloads
application data, or the other way round. Possible data types of the external layer are:
ACCP, CHAR, CLNT, CUKY, CURR, DATS, DEC, FLTP, INT1, INT2, INT4, LANG, LCHR, LRAW, NUMC, PREC, QUAN, RAW,
TIMS, UNIT, VARC.

What are the Data types of the ABAP/4 layer?


Possible ABAP/4 data types are:
C: Character.
F: Floating-point number in DOUBLE PRECISION (8 bytes).
I: Integer.
N: Numerical character string of arbitrary length.
D: Date, format YYYYMMDD.
S: Time stamp YYYYMMDDHHMMSS.
T: Time of day HHMMSS.
V: Character string of variable length, length is given in the first two bytes.
X: Hexadecimal (binary) storage.
P: Amount or counter field (packed; implementation depends on hardware platform).

How is conversion of data types done between ABAP/4 & DB layer?


Conversion between ABAP/4 data types and the database layer is done within the database interface.

How is conversion of data types done between ABAP/4 & external level?
Conversion between the external layer and the ABAP/4 layer is done in the SAP dialog manager DYNP.

A field containing currency amounts (data type CURR) or, quantity amounts (data type QUAN) must be assigned to a
reference table and a reference field. Explain.
As a reference table, a system table containing all the valid currencies/quantities, is assigned or any other table which
contains a field with the currency key format (data type CUKY) or, quantity units format (data type UNIT). This field is
called as reference field. The assignment of the field containing currency/quality amounts to the reference field is made
at runtime. The value in the reference field determines the currency of the amount or, the quantity unit.

What are conversion routines?


Non standard conversions from display format to sap internal format and vice-versa are implemented with so called
conversion routines. They are identified by a five-place name and are stored as a group of two function modules. The
function modules have a fixed naming convention. The following function modules are assigned to conversion routine
xxxxx:
CONVERSION_EXIT_xxxxx_INPUT
CONVERSION_EXIT_xxxxx_OUTPUT
The INPUT module converts from display format to internal format, and the OUTPUT module converts from internal
format to display format.

What are elementary search help and a collective search help?


Elementary search helps: It defines a search path where we 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. It is for f4
help.
Collective search helps: Combination of elementary search helps. When we need to fetch data based on multiple
selection criteria, more than one table is selected from multiple tables.

What is the difference between an elementary search help and a collective search help?
 Elementary search helps describe a search path. The elementary search help must define where the data of the hit
list should be read from (selection method), how the exchange of values between the screen template and selection
method is implemented (interface of the search help) and how the online input help should be defined (online
behavior of the search help).
 Collective search helps combine several elementary search helps. Collective search help thus can offer several
alternative search paths.
 An elementary search help defines the standard flow of an input help.
 Both elementary search helps and other search helps can be included in a collective search help. If other collective
search helps are contained in collective search help, they are expanded to the level of the elementary search helps
when the input help is called.

How to create Parameter-ID?


Parameter ID can be created in the table TPARA. Just enter the name of the parameter id in the table and that
parameter ID will be created. In SE11 transaction, during creating a data element and enter the parameter id at the
Further Characteristics tab at the parameter Id section.

What are Aggregated Objects?


Views, match codes, and lock objects are also called aggregate objects because they are formed from several related
tables.

What is a Match Code?


Match Code is a tool to help us to search for data records in the system. Match codes are an efficient and user-friendly
search aid where key of a record is unknown.

Difference between Search Helps and Match Codes


 Search help: adding f4 functionality is search help (adding help for any topic). In 4.6b name is call it as match code.
 Match code: adding search help for the input field is called as match code object.

What are the two levels in defining a Match Code?


 Match Code object
 Match Code Id.

What is the maximum number of match code Id's that can be defined for one Match code object?
36. A match code Id is a one character ID which can be a letter or a number.

Can we define our own Match Code ID's for SAP Match codes?
Yes, the numbers 0 to 9 are reserved for us to create our own Match Code IDs for a SAP defined Match code object.

What is an Update type with reference to a Match code ID?


If the data in one of the base tables of a match code ID changes, the match code data has to be updated. The update
type stipulates when the match code is to be updated and how it is to be done. The update type also specifies which
method is to be used for building match codes. You must specify the update type when you define a match code ID. The
following update types are possible:
 Update type A: The match code data is updated asynchronously to database changes.
 Update type S: The match code data is updated synchronously to database changes.
 Update type P: The match code data is updated by the application program.
 Update type I: Access to the match code data is managed using a database view.
 Update type K: Access to the match code is achieved by calling a function module.

What are the differences between a Database index and a match code?
 Match Code can contain fields from several tables whereas an index can contain fields from only one table.
 Match code objects can be built on both transparent tables and pooled and cluster tables.

What is a View?
A view is a logical 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.

How many types of Views are there?


Database View (SE11): Database views are implement an inner join, i.e., only records of the primary table (selected via
the join operation) for which the corresponding records of the secondary tables also exist is fetched. Inconsistencies
between primary and secondary table could, therefore, lead to a reduced selection set. In database views, the join
conditions can be formulated using equality relationships between any base fields. In the other types of view, they must
be taken from existing foreign keys. That is, tables can only be collected in maintenance or help view if they are linked to
one another via foreign keys.
Projection View: Projection views are used to suppress or mask certain fields in a table (projection), thus minimizing the
number of interfaces. This means that only the data that is actually required is exchanged when the database is
accessed. A projection view can draw upon only one table. Selection conditions cannot be specified for projection views.
Maintenance View (SE54): Maintenance views enable a business-oriented approach to looking at data, while at the
same time, making it possible to maintain the data involved. Data from several tables can be summarized in a
maintenance view and maintained collectively via this view. That is, the data is entered via the view and then distributed
to the underlying tables by the system.
Help View (SE54): Help views are used to output additional information when the online help system is called. When the
F4 button is pressed for a screen field, a check is first made on whether a match code is defined for this field. If this is not
the case, the help view is displayed in which the check table of the field is the primary table. Thus, for each table no
more than one help view can be created, that is, a table can only be primary table in at most one help view.

What JOIN conditions are used by Views?


Database views implement Inner Join whereas Maintenance Views and Help Views implement an outer join.
Using the inner join, you can retrieve records which are there in the entire table involved in the view i.e. you only get the
records of the primary table which also have the same record in the secondary tables of the view. Using an outer join
you can also select the records for which there are no entries in the secondary table.
The join conditions for database views can be formulated using equality relationships between any base fields. The join
conditions for the other view types must be obtained from existing foreign keys. Tables therefore can only be combined
into a maintenance view or help view if they are linked to one another with foreign keys.

What is the use of Outer Join and Inner Join?


With the use of Outer Join you can join the tables even there is no entry in all the tables used in the view. In case of
Inner Join there should be an entry in al the tables use in the view.

Can we write Inner join With Pooled Table?


No, because inner join works only for foreign key relation. So in pooled table in between tables there is no foreign key
relation.

What is table maintenance generator? What is the transaction code?


Table maintenance generator is nothing but making a table available for adding records and deleting records. Table
Maintenance Generator (TMG) is a tool which is used to create equipment by which customized tables created by end
users can be changed as required, such as making an entry to that table, deleting an entry etc. It is used to update the
mass data for the table. Table maintenance is generally used when creating maintenance view. To update the table you
need to activate the table maintenance generator, so that in the maintenance view one can maintain the table.SM30 is
the transaction code to create table maintenance generator.

Have you created Maintenance dialog or Table Maintenance?


At the time of creating table through, there is a check box for table maintenance allowed. So if you want to activate the
table maintenance, just mark this box. Once table gets activated, you can change its contents through SM30 or Through
Table Maintenance (SE54).

How can I copy a standard table to make my own ztable?


Use SE11 & there is copy(ctrl+f5) button is available after copy activate the ztable, it's simple to copy a database table,
but note that if in database table maintenance generator is available then you have to define your maintenance
generator in your copied ztable.

It is possible to access the data of a DB view in ABAP/4 programs both with OPEN SQL and with NATIVE SQL.
(TRUE/FALSE)
True.

Since the Database View is implemented on a database, only transparent tables can be used to create them.
(TRUE/FALSE)
True.

What is locking?
When two users simultaneously attempt to access the same data record, this is synchronized by a lock mechanism.
When dialog transactions are programmed, locks are set and released by calling certain function modules. These
function modules are generated automatically from the definition of so-called lock objects in the ABAP/4 Dictionary. To
synchronize the access to a table by setting and removing locks, a Lock object has to be defined in the ABAP/4
Dictionary. Activating the lock object automatically creates function modules for setting and removing locks. These
function modules must be included when programming interactive transactions.
Lock Mechanism: Lock Mechanism prevents a new database operation being started till an existing one has been
correctly completed. When conversion is done, lock is created automatically and released only when conversion is
successful. Clearing of locks restart adjustment attempt is made to continue conversion at the point of termination
Cancel adjustment lock entry is simply deleted from table.
To set locks, a lock object must be defined in the ABAP/4 Dictionary. In this lock object, those tables in which data
records are to be locked by calling a lock are determined. All tables included in a lock object must be connected to each
other via foreign keys. The key fields of the tables in a lock object form the Lock arguments for the tables. The lock
arguments are the basis for formulating the logical condition for identifying the records to be locked.
When activating this lock object, two function modules with the names - ENQUEUE_<Object_name> and
DEQUEUE_<Object_name> are generated.
An Example of Locking:
Problem: You wish to prevent a user from being able to change the name of a course or the name of the professor with
responsibility for the course at a time when another user is editing the course description (which contains this
information).
Solution: The problem described above can be solved by defining a lock object E_UKURS. This is done by defining
primary and secondary tables in the lock object. Table UKURS is check table of table UKRSB, so UKURS should be
selected as primary table and UKRSB as secondary table of the lock object.
The Lock argument in this case is the field combination FABNR, KRSNR, and SPRAS (i.e. Primary Key Combination).
The Lock mode Shared is to be selected here. This allows several users to access the data simultaneously in display
mode.
The lock mode in the generated function modules for setting (ENQUEUE_E_UKURS) and releasing (DEQUEUE_E_UKURS)
locks is therefore set to share as default, but can be overridden by calling the function modules.
If the function module ENQUEUE_E_UKURS is called with FABNR = '1' and KRSNR = '3', the record for course 3 in faculty
1 is locked in table UKURS. Furthermore, all the course descriptions for this course are locked in table UKRSB since field
SPRAS was not specified when the function module was called. In such cases, the lock is made generically for a field
which is not defined.
If the function module DEQUEUE_E_UKURS is now called with FABNR = '1', KRSNR = '3' and SPRAS = 'D', the German
course description is unlocked. All other course descriptions remain locked.

What does a lock object involve?


 The tables
 The lock argument.

What are the different kinds of lock modes?


 Shared lock
 Exclusive lock
 Extended exclusive lock.

Name the two types of locks as used in SAP.


Database locks and logical locks

How can a user-defined lock object be called in the transaction?


By calling the function module Enqueue <lock object> and Dequeue <lock object> in the transaction.
Which is the First character of creating Lock Object?
Lock objects always starts with character 'E'.

You wish to prevent a user from being able to change the name of a course or the name of the professor with
responsibility for the course at a time when another user is editing the course description (which contains this
information). How you will do it?
Lock Object.

Use of Editor Lock. (True / False)


 Others can see as well as change the program. F
 User can see as well as change the program. T
 Others can see but cannot make the changes in the program. T
 User can see but not make change to the program. F

What is the difference between Table and Template?


Table is a dynamic and template is a static.

What is database utility?


The database utility is the interface between the ABAP/4 Dictionary and the relational database underlying the SAP
system. You can call the database utility from the initial screen of the ABAP/4 Dictionary with Utilities → Database utility.
The database utility allows you to create, delete and convert objects from the ABAP/4 Dictionary in the database.
Whenever you make a change to a dictionary object that affects the underlying database, the database utility is
activated. Usually it works silently behind the scenes, but occasionally the database utility will prompt you for
information. This occurs when an error is encountered or when existing data must be converted.In addition the
database utility supports structural adjustments - so-called conversions - of an object definition in the database to
changed definitions of the object in the ABAP/4 Dictionary. The operations, which the database utility executes for an
object, are logged. The object log can be displayed from the database utility.
The database utility offers several analysis options. It can:
 Check whether a table in the database already contains records.
 Convert data (i.e., change field lengths and data types, etc.)
 Display the definition of the table in the database.
 Activate objects in the ABAP Dictionary & display the runtime object for a table.
 Create tables and indices.
 Check consistency between the database table and the runtime object.
 Check consistency between the definition of the table in Dictionary maintenance (SE11) and the runtime object.
 Perform all standard table operations in the database that were entered in the ABAP Dictionary.
The database utility provides the interface to the DBMS by automatically generating the Data Definition Language (DDL)
that the DBMS understands.

You might also like