You are on page 1of 20

Name: Manoj K

Employee ID: 2078378


COHORT CODE: EAS22SAP042 
1. SAP R/3 Architecture
where R stands for RealTime and 3 refers to three-tier application architecture
(Database,Application Server and Client).
Presentation layer: Receives user input and produces a method request.
Application layer: Receives and processes a process request using the Software
Logic Application.
Database Layer: All data is saved and recovered.

2. Domain and Data Elements in SAP


The domain is used for the technical definition of a table field such as field type
and length,
the data element is used for the semantic definition (short description).

3. Views in Dictionary
 grouping of columns in one or more database tables in accordance with an
application-specific view. 
Four different view types are supported.
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.

4. Structure, APPEND Structure in DDIC.


APPEND Structure - for Table Enhancement .. Adding additional fields to the
standard Table But without changing the standard table’s structure
There are three types of structures:
 Flat structures: A flat structure only references elementary types.
 Nested structures: A nested structure references at least one further structure,
but not a table type.
Deep structures: You can distinguish the three types of structures in the
following figure.A deep structure references at least one table type.
Append structures are used for enhancements which are not provided for in the
standard
Note:Append structures can only be created for transparent tables and
structures.

5. Currency and Quantity Fields In Table Creation


CURRENCY and QUANT fields are special as they need a UNIT that is for
currency u need currency type like EURO, USD etc, where as for quantity you
need to know the unit that is KM, HOURS etc etc.

SO whenever you have such fields in your table you need to have a reference
field to assign the UNIT for these fields.

So you will create another field in the table for UNIT and make this as a
reference for your CURR or QUANT field.

The data will be inserted normally at the same time we have to insert the UNIT
field.

Also when we retrive the data the reference field is used to perform conversion
for these fields so that in the UI they appear as per the UNIT.

6. Types of Indexes in DDIC


There are two types of indexes available in DDIC. such as primary index and
secondary index.
Primary Index - Created by default with primary Key Fields … As a result, the
data in the table is arranged in the sorted order of Primary index/Key Fields . Is
the default functionality
Secondary Index – on Non-key Fields when we access the data frequently based
on Non-key fields. We have to Create 2nd ry index explicitly

7. Types of DB Tables in DDIC


There are three types of database tables :
 Transparent tables.
 Pooled tables.
 Cluster tables
 Transparent - table – is the Default type – for Application Data.
 Pooled Tables should be part of Table Pool – is used for Internal Data.
N pooled tables make 1 Table pool
Cluster Tables should be part of Table Cluster – is used for Internal Data and
also in HR module. N cluster tables make 1 Table cluster.

8. Purpose and Types of Internal Tables


There are three types of internal table. They are - Standard Tables, Sorted
Tables, and Hashed Tables.
Purpose : to accommodate and process multiple records - preferably from DB
Table(s)
9. System variables and name few
System variables are special variables created during a working session to keep
system-required information, such as the number of cases read by the system
System Date
 System Time
 System Logon user
 Database
 Operating Sys
 Current Page
 Current Prog name
…
Note : All the System Variables are maintained in DB Table/structure - SYST
• Ex : SYST-DATUM or SY-DATUM

10. Diffrence between IF, CASE, DO , ENDDO


IF: In case of IF…. ELSE statements, if the expression evaluates to true then the
IF block of code will be executed. Otherwise, ELSE block of code will be
executed. 

CASE: The CASE control statement is used when you need to compare two or
more fields. 
DO and ENDDO: The statements DO and ENDDO define a control structure,
which can contain  a closed statement block statement block. Without the
addition n TIMES, the statement block  is repeated until it is exited using one
for the statements for leaving loops. In particular, the  statement EXIT is ideal
for exiting a loop completely.

11. Explain EXIT , CONTINUE

Exit is leaving the loop. Continue continues with the next item in the loop.

The EXIT command leaves the loop, do, select … structure where you are. This
is jumps out of the loop structure and executes the firs command after endloop,
endselect….

The CONTINUE comand jumps to the end of the loop structure but
continues executing the next iteration of the loop structure.

12. Explain What is Work Area and Internal Table


The area where this record is kept is called as work area for the internal table.

Internal table can have more than one entry.but work area can hold at a time
only one entry.

13. Explain Itab Operations


1.append- to append the workarea record at the last position of internal table.

2. Insert- to insert the records into internal table in a specific location.


3.Delete- To delete the records of Internal Table.
4.Modify-Used to Overwrite the record values of an internal we can modify
single record and multiple records of an internal table.
5.Describe-to know the count of internal table records.
6. Sort-Arrange the records of internal table in an
order(Ascending/Descending).
7.Refresh-to clear the contents/records of internal table.
8. Clear-to clear the contents/records of variable/workarea/internal table.
9.Free- to free up the memory occupied contents/records of
variable/workarea/internal table.
14. Expain the Foreign Key Relation

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.

15. How to Delete Duplicates from ITAB

Use the statement "Delete Adjacent duplicate from table ITAB(Internal


Table)." If you want to delete the similar records with specific fields, use option
"Comparing" followed by the fields.

16. SY-TABIX vs SY-INDEX

Sy-tabix is used to find the current line in the internal table; it's a current line
index.
Whereas sy-index in used to find the number of current pass in the loop
statement.

17. Role of Application Server


Application server instances provide the actual data processing functions of a
system and offer the corresponding services. Instances are started, stopped,
and monitored as one unit.

18. Types Of Work Process in Applications

Work Process
Use and Description
Type Name
To Fulfill all requests for execution of dialog steps triggered by an active
Dialog
user or execute dialog programs.
It executes those programs that run without user interaction or executes time
Background
dependent or event controlled background jobs.
Update It executes Update Requests or Asynchronous database changes which are
Work Process
Use and Description
Type Name
controlled by a COMMIT WORK statement in a dialog work process.
It pass sequential data flows onto Printers or Print Formatting to printer, file
Spool
or database.
Administers the lock table in shared memory or If SAP transactions have to
Enqueue
synchronize themselves it executes locking operations.

19. SAP Application Server architectures

SAP NetWeaver Application Server is the central foundation for the entire
SAP software stack. It also provides a platform for other SAP NetWeaver
Application Server components (Portal, XI, and so on), as well as for ABAP
and Java applications. The full Java EE standard is supported. SAP NetWeaver
Application Server is the further development of the SAP Web Application
Server. 

20. Database View vs Help View 

Database View 
 Data from One or More Tables Implements Inner Join creates a database view
in the underlying database when you activate the view. Allows data selection in
the database. Since the join operation is executed  in the database in this case,
you can minimize the number of databases accesses a database view can only
contain transparent tables. 
 Help View 
  You create a help view if a view with an outer join is needed as 
  a selection method of a search help. 
 
21. Primary key 

Primary Key field(s) for the unique identification of records in the table 
Each table must have a primary key and it must be at the beginning of the table. 
 
22. Table Maintenance Generator

Table Maintenance Generator (TMG) - to Created Multiple Entries at the same


time via table Control. 
 
23. CLEAR, REFRESH, FREE

1.free : It will free the memory of the Internal table and delete the
records.
FREE <Any Variables>. WA, ITAB, V_no
2.refresh : It will delete the records but memory will be there.
REFRESH <Only ITAB>. 
3.clear : It will clear the header of the internal table records will be there in
internal table.
CLEAR <Any Variables>. WA, ITAB, V_no
 

24. Inner Join Vs Outer Join 

INNER JOIN: to return all rows from both tables where there is a match. i.e.. in
the resulting table all the rows and columns will have values.
In OUTER JOIN the resulting table may have empty columns. Outer join may
be either LEFT or RIGHT .
LEFT OUTER JOIN returns all the rows from the first table, even if there are
no matches in the second table. 
RIGHT OUTER JOIN returns all the rows from the second table, even if there
are no matches in the first table. 
OUTER JOIN: 
There are three types of outer joins namely: 
Left Outer Join---For retrieving all the columns from the first table irrespective
of the column match. 
Right Outer Join---For retrieving all the columns from the second table
irrespective of the column match 
Full Outer Join---For retrieving all the columns from both the tables irrespective
of column match. 
 
25. Search Help 

List of Possible values. Displayed for F4 of the respective Input Field Search


Help 
 
26. Role of Selection Method in Search Help
 
In the Search help parameter area, select fields of the selection method as
the parameter. To do this, use the input help (F4 help). Select the fields that
must be used in the dialog box for value selection or in the hit list. 
 

27. Which Itab can be used without any restrictions 


Hashed  
 
28. Search time Depends on no.of records in Hashed table 

No, it executes hashing algorithm to find the location of the record 


 
29. Explain Lock Objects and the Function Modules 

• The SAP system synchronizes several users’ simultaneous access to the same
data records with a lock mechanism.
• When you activate a lock object in the ABAP Dictionary, the system
automatically creates function modules for setting (ENQUEUE_<lock object
name>) and releasing (DEQUEUE_<lock object name>) locks.

 
30. Explain Primary Key in a DDIC Table 

Primary Key field(s) for the unique identification of records in the table 
Each table must have a primary key and it must be at the beginning of the table. 
 
31. Standard Itab's with Unique keys 

Each internal table has a primary table key that enables access to individual
rows in the table by means of a key specification. The components of the
primary table key are declared using UNIQUE. 
 
32. Chain Operator 

Chain operators can be used where we are declaring more than two variables or
executing two or more routines with a single command line 
Data: A type d, 
B type d, 
C type d. 
 
 
33. Explain the Purpose Comments and How to Comment in ABAP

A comment is an explanation that is added to the source code of a program to


help the person reading the program to understand it.
 must be in the 1st column to comment the whole Line.
 Comment from between the lines using double quotes (“).
 
34. Work area vs Internal Table

Work Area – Single Record Operations are through WA 


ITAB – Multiple Records Operations are through Itab 
 
35. What is Secondary Index and when to go for it

Secondary Index – on Non-key Fields when we access the data frequently based
on non-key field.
We have to Create 2nd ry index explicitly 
Select …. Where land1 =? “2nd ry index is referred if exist on land1 
 Select …. Where pernr =? Refers primary Index as pernr is Pkey. 
 
36. Explain the Foreign Key and the pre-requisites

A foreign key is the one that is used to link two tables together via the primary
key. It means the columns of one table point to the primary key attribute of the
other table. It further means  that if any attribute is set as a primary key attribute
will work in another table as a foreign key attribute. 

Both Fkey, Check table field should have referred to Domain 

Check Table field must be part of primary Key 


 
 
 
37. Explain Control break statements 

Control break statements are statements which are used to control the sequence
of execution of statements within LOOP....ENDLOOP. These statements are
executed only within a loop end loop. 
 
 
 
38. Explain Buffering and types of Buffering 
Buffering is recommended for tables whose data is NOT changed frequently. 
Full Buffering - Whole Table is Buffered irrespective of selected Data.
Recommended for tables with a small amount of Data 
Single Record buffering - Table with Selected Data only. Recommended for 
table with any data 
Generic Buffering - When a read is performed on a row, all rows are loaded into
the SAP buffer that match this row in a left-justified part of the primary key. 
 
39. What is the Search Help Exit

A search help exit is a function module that has a predefined interface. A search
help exit is called at certain times by the help processor. The administrative data
of the help processor is passed to the search help exit using the interface. 
 
40. Primary Key Vs Foreign Key

Primary Key field(s) for the unique identification of records in the table Each
table must have a primary key and it must be at the beginning of the table.

 A foreign key is the one that is used to link two tables together via the primary
key. It means the columns of one table point to the primary key attribute of the
other table. It further means  that if any attribute is set as a primary key attribute
will work in another table as a foreign key attribute. 
Week-2
1. Classical Report Events
Classical Report Events (Applicable up to Basic List)

Event Triggering Time What make Sense

INITIALIZATION Before Display the Selection Screen(if Initialize the Selection


exist) else as 1st event Screen with Calculated
Values as default values

AT SELECTION- After Input and Before leaving the Validate the Input and
SCREEN Selection Screen Error messages for invalid
Data

START-OF- After leaving the selection Screen if Actual business logic for
SELECTION exist. the Invlid Input
Is the default event in the Executable
program and all the executable
statements are part of this event itself
by default

TOP-OF-PAGE At the beginning of each New Page To Print same heading for
all Pages

END-OF-PAGE At the END of each New Page To Print same Footer for
all Pages

2. GUI Status

A GUI status is an independent component of an ABAP program which you can


create using the Menu Painter in the ABAP Workbench.
There are three different types of GUI statuses:
 Dialog status
 Dialog box
 Context menu.

3. At Selection-Screen
Triggering Time: After Input and Before leaving the Selection Screen
What makes Sense: Validate the Input and Error messages for invalid Data

4. Initialization
Triggering Time: Before Display the Selection Screen (if exist) else as 1st event
What makes Sense: Initialize the Selection Screen with Calculated Values as
default values

5. Top-of-Page vs Top-of-Page During Line Selection


Top of Page
Triggering Time: At the beginning of each New Page
What makes Sense: To Print same heading for all Pages
End of Page
Triggering Time: At the END of each New Page.
What makes Sense: To Print same Footer for all Pages.

6. Explain Interactive Report Events

Event Triggering Time What make Sense

AT LINE-SELECTION When any line is Generating next list level


Selected/Double clicked list
from any output list
TOP-OF-PAGE At the beginning of each To Print same Footer for
DURING LINE- New Page of all the all Pages of all the
SELECTION. Secondary Lists Secondary Lists

7. SY-LSIND, SY-UCOMM
sy-lsind is the index of the current list
sy-ucomm is used for doing the functions what the user wishes to do at that
particular event . You can use it on menus and other places.

8. Select-Options
To accept Multiple Values/Ranges as input during Selection.
Syntax: SELECT-OPTIONS <name> FOR <Variables>.

9. What is header line


Header line acts as Implicit WA and with the name of ITAB self.
Header Lines are not recommended and not allowed in OO-ABAP

10. Order of Classical Report Events


 Initialization
 At Selection Screen
 Start of Selection
 Top of Page
 End of Page

11. Purpose of Report


To Analyze the current state and help in decision making

12. Get Cursor


GET CURSOR FIELD field [field_properties].
Returns the name of the displayed field in field after a user action. This name is
where the cursor is positioned in the currently displayed list.
When the 2nd ry list is based on the Selected Column from Output list
GET CURSOR FIELD <v_fnam> VALUE <v_fval>.

13. Conversion Routine


This keyword is used as a conversion operator. To convert a variable with one
data type to another
During the GET CURSOR, the value comes for Output list i.e. external
value/format and the same has to be converted explicitly into Internal/DB
format(value) before using that value for further Selection from DB as DB has
internal format/value.
FM to Convert from External to Internal
FM ‘CONVERSION_EXIT_<routineName>_INPUT
FM to Convert from Internal to External
FM ‘CONVERSION_EXIT_<routineName>_OUTPUT

14. Break Point vs Watch Point


Break Point: signal to interrupt the program execution so that we resume step
by step by see the live result.
Watch Point: interrupt the program execution by watching the content of a
variable.

15. Session Break Point Vs External Break Point


Session Break point - active for that login period Only from the same system
execution
External Breakpoint - active for particular duration for External Execution
i.e., from remote i.e. From other SAP, web.

16. F5, F6,F7,F8 - Role of these things in Debugging


F5 - Single Step / Step by Step Execution
F8 - Execute up to the next break/watch point if exist else execute the whole
program without any interruption
F7 - To Return from the definition of the Function, Form, Module.
F6 - Execute the Calling statement (CALL FUNCTION…PERFORM. as a
single statement

17. Role of Events in any programs


Action -> Event -> attach the response to event
Event is the information about the Action/Timing. Responding/handling event is
nothing but responding to the respective action

18. Role of Text Elements


Text Elements for which we can maintain Language translations Selection texts,
text symbols, headings are part of Text Elements

19. Push Buttons on Application Toolbar and F codes


Maximum 5 buttons are allowed whose F codes are fixed i.e.
FC01, FC02, FC03, FC04, FC05. and these buttons are through "FUNCTION
KEY 1" through "FUNCTION KEY 5" are allowed and their Function text is
through sscrfields-functxt_01, sscrfields-functxt_02,03,04,05

20. Size Category as part of Technical Settings


The size category determines the probable space requirement for a table in the
database. You can select the categories 0 to 4 for your table. Each category is
assigned a specific fixed storage area value in the database. When you create a
table, the initial space is saved for it in the database.

21. Data Class


The Physical area (table space) in DB for the table to be stored. If you choose
the data class correctly, your table is automatically assigned to the correct area
(table space or DB space) of the database when it is created. 
 

22. Any 5 transaction codes and purpose and Any 5 Standard Tables

Transaction Codes 
SE11 – Creating data elements, tables, domains, structures etc. 
SE38 – ABAP Editor 
SE80 – Object Navigator 
SE41 - Menu Painter 
SE51 – Screen Painter 
  
Standard Tables 
KNA1 
VBAK 
LFA1 
MARA 
MBEW 
 
23. Subroutines Vs Function Modules 

Subroutines 
Pass by Reference 
Pass by Value 
Pass by Value and Result 

In contrast to normal subroutines function modules have uniquely defined 


interface. Subroutines do not return values. Sub routines do not return
exceptions. Subroutines cannot be tested independently. Declaring data as
common parts is not possible for function modules. 
Function modules are stored in a central library. 
 
24. Passs by Reference and Pass by Value
 
Pass by Reference - USING/CHANGING 
Changes to Formals are reflected in the respective Actuals immediately 

Pass by Value - USING VALUE () 


Changes to Formals are NOT reflected in the respective Actuals at all. 
 
25. Pass By value and Result 

Pass By Value & Result - CHANGING VALUE () 


Changes to Formals are reflected in the respective Actuals but NOT
immediately and it is only after successful completion of subroutine. 
 
 
 
26. Define, Raise and Handle Exceptions of a Function Modules

Syntax 
RAISE [RESUMABLE] EXCEPTION 
  { {TYPE cx_class [ message] [EXPORTING p1 = a1 p2 = a2 ...]} 
  | oref }. 
 
The statement interrupts execution of the current statement block and raises a
class-based 
exception.  During handling, processing can only be resumed after the statement
RAISE EXCEPTION. We need to define the Exception under the tab
“Exception” in the Function Builder. We have to use the MESSAGE …
RAISING EXCEPTION_1 syntax to raise the exception. 
 
27. BDC Programming
 
B – Batch 
D – Data 
C – Communication 

All the standard transactions can create only one record at a time. So, a custom
BDC program is needed to call that transaction repeatedly to create bulk of
records 
 
28. BDC Call Transaction Steps

 To access the screens and screen fields a transaction recorder is used. 


 Transaction code for transaction recorder is –SHDB. 
 Navigate to New Recording and give a preferred name. 
 Enter the particular transaction code which has to be recorded. 
 Start Recording. 

 
29. BDC Session Method Steps
 Also via transferring the data via Screens and Screen Fields. 
 FM ‘BDC_OPEN_GROUP’. 
 Loop at it_file into wa_file. Performs. Insert data and tcode into
session FM ‘BDC_INSERT’ Endloop 
 FM ‘BDC_CLOSE_GROUP’. 
 Tcode – SM35 – to process the Session then database updating takes
place. 
 Error log is created implicitly at the end of session processing. 
 

30. FMs used in Session Method and purpose

FM ‘BDC_OPEN_GROUP’ - it is used to open the session. It takes program


name, session name etc.
FM ‘BDC_INSERT’ - is used to add the BDC records to the session 

FM ‘BDC_CLOSE_GROUP’ - once all records are added to session then we


will close the session using close group function. 


 
31. Role of BDC programming
 
All the standard transactions can create only one record at a time. So, a custom
BDC program is needed to call that transaction repeatedly to create bulk of
records 
 
 
 
32. Types of FMs

Regular Function Module: A Regular Function Module is the default option.


This kind of Function Module is executed immediately and synchronously on
your current SAP system.
Remote Enabled Function Module: Remote Function Modules can be called
by other SAP and non-SAP systems utilizing the RFC protocol.
Update Function Module: Update Function Modules are not executed
immediately. They are scheduled for execution in an update work process. This
update process is triggered by the statement COMMIT WORK.

 
 
33. Role of Transaction Recorder in BDC Program 

BDC recording provides a simple way to generate BDC code for executing
transactions. 

By running SHDB and recording a BDC, you can then simply convert it to
program code. This 
prevents you from having to figure out all the function codes and screen
numbers manually.  Once you have this BDC code, you can decide whether to
use it in a call transaction or a SM35 batch input session. 
 
34. Different Modes of Display during Call Transaction 

A - is all screen mode. All the screens of transaction are displayed. 


N - is no screen mode no Screen is displayed when you executed the
transaction. 
E - is error screen Only those Screen are displayed where in you have error
record. 
 
35. Control Break Events/Statements 

Control break processing is used to execute a piece of code whenever a specific 


condition in the data is detected during the processing of internal table loop. 
The following control break statements are available within LOOP and
ENDLOOP. 

35. At Selection-Screen output 


 
At selection-screen output is triggered when the selection screen is loaded in
memory before being displayed.
 
  
 
37. How Session Method differs from Call Transaction

CALL TRANSACTION
SESSION METHOD
METHOD
Immediate Updating in
Data is not updated in database
Database
tables
unless session processed table.
No Sy - Subrc is returned Sy - Subrc is returned
Error Log is created for error Error need to be handled
records explicitly
Updation in databse table is Updation in databse table is
always Synchronomous Asyncronomous

Question no: 40, 14, 22, 23 in the second week are Repeated.

You might also like