90
ABAP / 4 INTERVIEW QUESTIONS WITH ANSWERS 1) What is SAP R/3? Ans SAP R/3 refers to Systems Application and Product for data processing Real-time having a 3 tier architecture i.e. Presentation layer, Application layer and Database layer. 2) What are the programming standards followed? 3) The Pictures are of actually taken at the Studio of Gucci Handbags Outlet What are the contents in technical specifications? Ans There are five contents in Technical Settings: Data Class, Size Category, Buffering Permission, Buffering Type and Logging. 4) What is an instance? Ans When you call a function module, an instance of its function group plus its data, is loaded into the memory area of the internal session. An ABAP program can load several instances by calling function modules from different function groups. 5) How to take care of performance in ABAP Development? 6) What is Function group? Difference between function group and function module? Ans Function Groups act as containers for Function Modules that logically belong together. Function Groups 1) These cannot be defined in a Function Module. 2) It cannot be called. 3) They are containers for Function Module.

Sap Inter Ques1 June2013

Embed Size (px)

Citation preview

Page 1: Sap Inter Ques1 June2013

         ABAP / 4 INTERVIEW QUESTIONS WITH ANSWERS

1)         What is SAP R/3?

Ans      SAP R/3 refers to Systems Application and Product for data processing Real-time having a 3 tier architecture i.e. Presentation layer, Application layer and Database layer.

2)         What are the programming standards followed?

3)        The Pictures are of actually taken at the Studio of Gucci Handbags OutletWhat are the contents in technical specifications?

Ans      There are five contents in Technical Settings: Data Class, Size Category, Buffering Permission, Buffering Type and Logging.

4)         What is an instance?

Ans      When you call a function module, an instance of its function group plus its data, is loaded into the memory area of the internal session. An ABAP program can load several instances by calling function modules from different function groups.

5)         How to take care of performance in ABAP Development?

6)         What is Function group? Difference between function group and function module?

Ans      Function Groups act as containers for Function Modules that logically belong together.

Function Groups

1)      These cannot be defined in a Function Module.

2)      It cannot be called.

3)      They are containers for Function Module.

Function Modules

1)      These must be defined in a Function Group.

2)      It can be called from any program.

3)      They are not containers for Function Group.

7)         What is the difference between ‘Select single * ‘ and ‘Select upto 1

Page 2: Sap Inter Ques1 June2013

rows’?

Ans      ‘Select single *’ – The result of the selection should be a single entry. If it is not possible to identify a unique entry, the system uses the first line of the selection. For e.g.

DATA : ITAB TYPE ZREKHA_EMP.

SELECT SINGLE * FROM ZREKHA_EMP INTO ITAB

WHERE EMPNO = ‘00101’ AND DEPTNO = ‘0010’.

WRITE : / ITAB-EMPNO, ITAB-EMPNAME,ITAB-DEPTNO.

Select upto 1 rows -

8)         What Function does data dictionary perform?

Ans      Central information repository for application and system data. The ABAP Dictionary contains data definitions (metadata) that allow you to describe all of the data structures in the system (like tables, views, and data types) in one place. This eliminates redundancy.

9)         Difference between domain and data element? What are aggregate object?

Ans      Domain - Specifies the technical attributes of a data element - its data type, length, possible values, and appearance on the screen. Each data element has an underlying domain. A single domain can be the basis for several data elements. Domains are objects in the ABAP Dictionary.

Data Element - Describes the business function of a table field. Its technical attributes are based on a domain, and its business function is described by its field labels and documentation.

Aggregate Object – Views, Match Code and Lock objects are called aggregate objects because they are formed from several related table.

10)       What is view? Different types of view. Explain?

Ans      View - A view is a virtual table containing fields from one or more tables. A virtual table that does not contain any data, but instead provides an application-oriented view of one or more ABAP Dictionary tables.

Different Types of View:

1)      Maintenance

Page 3: Sap Inter Ques1 June2013

2)      Database – It is on more than two tables.

3)      Projection – It is only on one table.

4)      Help

11)       Can u print decimals in type N? What is difference between float and packed data type?

Ans      No, we cannot print decimals in type N because decimal places are not permitted with N

data type.

Float Data Type: It cannot be declared in Parameters.

Packed Number: It can be declared in Parameters. For e.g.

PARAMETERS : A(4) TYPE P DECIMALS 2,

B(4) TYPE P DECIMALS 2.

DATA : C(4) TYPE P DECIMALS 2.

C = A + B.

WRITE : / ‘THE SUM IS’ , C.

12)       What is step-loop? Explain all the steps?

Ans      A step loop is a repeated series of field-blocks in a screen. Each block can contain one or more fields, and can extend over more than one line on the screen.

Step loops as structures in a screen do not have individual names. The screen can contain more than one step-loop, but if so, you must program the LOOP…ENDLOOPs in the flow logic accordingly. The ordering of the LOOP…ENDLOOPs must exactly parallel the order of the step loops in the screen. The ordering tells the system which loop processing to apply to which loop. Step loops in a screen are ordered primarily by screen row, and secondarily by screen column.

Transaction TZ61 (development class SDWA) implements a step loop version of the table you saw in transaction TZ60.

Static and Dynamic Step Loops

Step loops fall into two classes: static and dynamic. Static step loops have a fixed size that cannot be changed at runtime. Dynamic step loops are variable in

Page 4: Sap Inter Ques1 June2013

size. If the user re-sizes the window, the system automatically increases or decreases the number of step loop blocks displayed. In any given screen, you can define any number of static step loops, but only a single dynamic one.

You specify the class for a step loop in the Screen Painter. Each loop in a screen has the attributes Looptype (fixed=static, variable=dynamic) and Loopcount. If a loop is fixed, the Loopcount tells the number of loop-blocks displayed for the loop. This number can never change.

Programming with static and dynamic step loops is essentially the same. You can use both the LOOP and LOOP AT statements for both types.

Looping in a Step Loop

When you use LOOP AT with a step loop, the system automatically displays the step loop with vertical scroll bars. The scroll bars, and the updated (scrolled) table display, are managed by the system.

Use the following additional parameters if desired:

FROM and TO

CURSOR

13)       What is the initial value and maximum length of all data type?

Ans

Data Type

Initial field length

Valid field length

Initial valueMeaning  

Numeric types  I 4 4 0 Integer (whole number)  F 8 8 0 Floating point number  P 8 1 – 16 0 Packed number  Character types  C 1 1 – 65535 ‘ … ‘ Text field (alphanumeric

characters)  

D 8 8 ‘00000000′ Date field (Format: YYYYMMDD)  

  N 1 1 – 65535 ‘0 … 0′ Numeric text field (numeric characters)

  T 6 6 ‘000000′ Time field (format: HHMMSS)

Hexadecimal type  X 1 1 – 65535 X’0 … 0′ Hexadecimal field                    

Page 5: Sap Inter Ques1 June2013

14)       What are the ways to find out the tables used in the program?

Ans

15)       Can you have two detail lists from the basic list at the same time?

If yes how and if no why?

Ans

16)       What are the different functions used in sap script? What are the parameters used in each Function?

Ans      There are three different functions used in SAP Script:

1) OPEN_FORM

2) WRITE_FORM

3) CLOSE_FORM

Parameters in Each Function:

1) OPEN_FORM–

Exporting

Form

Language

2) WRITE_FORM–

Exporting

Element

Window

3)   CLOSE_FORM

17)       What is sequence of event triggered in report?

Ans      There are 6 events in report:

1) Initialization

Page 6: Sap Inter Ques1 June2013

2) At Selection-Screen

3) Start-of-Selection

4) Get

5) Get Late

6) End-of-Selection

7) Top-of-Page

8) End-of-Page

9) At Line Selection

10) At User Command

11) At PF (nn)

18)       What are standard layouts sets in the SAP Script?

Ans      There are four standard layouts in the SAP Script:

1) Header

2) Logo

3) Main Window

4) Footer

19)       What function module upload data from application server?

Ans

20)       What are the various types of selection screen event?

Ans      SELECTION-SCREEN BEGIN OF BLOCK ABC WITH FRAME TITLE T01.

SELECTION-SCREEN BEGIN OF SCREEN 500 AS WINDOW.

CALL SELECTION-SCREEN 500 STARTING AT 10 10.

21)       What do you know about a client?

Page 7: Sap Inter Ques1 June2013

Ans

22)       What are the system fields? Explain?

Ans      The ABAP system fields are active in all ABAP programs. They are filled by the runtime environment, and you can query their values in a program to find out particular states of the system. Although they are variables, you should not assign your own values to them, since this may overwrite information that is important for the normal running of the program. However, there are some isolated cases in which you may need to overwrite a system variable. For example, by assigning a new value to the field SY-LSIND, you can control navigation within details lists.

23)       What is SAP Script? What is the purpose of SAP Script? Difference between

SAP Script and Report?

Ans      SAP Script – It is the integrated text Management system of the SAP R/3 System. Two types – PC Editor & Line Editor.

Reports -  It is the way to display data fetched from database table onto screen or directly output it to a printer. Two types – Classical and Interactive.

24)       What is the use of occurs in internal table? Can u change occurs value in program?

Ans      Use of Occurs - If you use the OCCURS parameter, the value of the INITIAL SIZE of the table is returned to the variable

Data :  Begin of ITAB occurs 0,

End of ITAB.

Occurs or Initial Size – to specify the initial amount of memory that should be assigned to the table.

Yes, we can change the occurs value in program but output remains the same.

25)       Difference between SY-TABIX and SY-INDEX? Where it is used?

Can u check SY-SUBRC after perform?

Ans      SY-TABIX - Current line of an internal table. SY-TABIX is set by the statements below, but only for index tables. The field is either not set or is set to 0 for hashed tables.

* APPEND sets SY-TABIX to the index of the last line of the table, that is, it

Page 8: Sap Inter Ques1 June2013

contains the overall number of entries in the table.

* COLLECT sets SY-TABIX to the index of the existing or inserted line in the table. If the table has the type HASHED TABLE, SY-TABIX is set to 0.

* LOOP AT sets SY-TABIX to the index of the current line at the beginning of each loop lass. At the end of the loop, SY-TABIX is reset to the value that it had before entering the loop. It is set to 0 if the table has the type HASHED TABLE.

* READ TABLE sets SY-TABIX to the index of the table line read. If you use a binary search, and the system does not find a line, SY-TABIX contains the total number of lines, or one more than the total number of lines. SY-INDEX is undefined if a linear search fails to return an entry.

* SEARCH FOR sets SY-TABIX to the index of the table line in which the search string is found.

SY_INDEX - In a DO or WHILE loop, SY-INDEX contains the number of loop passes including the current pass.

 

26)       Difference between UPLOAD and WS_UPLOAD?

Ans      UPLOAD - File transfer with dialog from presentation server file to internal table. Data which is available in a file on the presentation server is transferred in an internal table. ASCII & Binary files can be transferred.

WS_UPLOAD - To read data from the presentation server into an internal table without a user dialog, use the function module WS_UPLOAD. The most important parameters are listed below.

Parameters Function  

 CODEPAGE Only for upload under DOS: Value IBM

 FILENAME Filename

 FILETYPE File type

       

27)       Why did u switch to SAP?

Ans

28) What is a Logical Database?

Ans Logical Databases are special ABAP programs that retrieve data and make

Page 9: Sap Inter Ques1 June2013

it available to application programs.

Use of LDB – is used to read data from database tables by linking them to executable ABAP programs.

29) What are the events used for Logical Database?

Ans Two Events –

1) GET - This is the most important event for executable programs that use a logical database. It occurs when the logical database has read a line from the node

and made it available to the program in the work area declared using the statement NODES

. The depth to which the logical database is read is determined by the GET statements2) PUT - The PUT statement directs the program flow according to the structure of

the logical database.

30) What is the difference between Get and Get Late?

Ans GET - After the logical database has read an entry from the node

.GET LATE - After all of the nodes of the logical database have been processed that are below

in the database hierarchy.

31) What are the data types of Internal Tables?

Ans There are three types:

1) Line

2) Key

3) Table

32) What are the events used in ABAP in the order of execution?

Ans Events are:

1. INITIALIZATION

2. AT SELECTION-SCREEN

Page 10: Sap Inter Ques1 June2013

3. AT SELECTION-SCREEN ON

4. START-OF-SELECTION

5. TOP-OF-PAGE

6. TOP-OF-PAGE DURING LINE SELECTION

7. END-OF-PAGE

8. END-OF-SELECTION

9. AT USER-COMMAND

10. AT LINE-SELECTION

11. AT PF

12. GET

13. GET LATE.

14. AT User Command

33) What are Interactive Reports?

Ans An output list which displays just the basic details & allow user to interact, so that a new list is populated based on user-selection. With interactive list, the user can actively control data retrieval and display during the session.

34) What are the commands used for interactive reports?

Ans Top-of-Page during line-selection

35) What are the system fields u have worked with? Explain?

Ans I had worked with the following (30) system fields:

1) SY-DBSYS - Central Database

2) SY-HOST - Server

3) SY-OPSYS - Operating System

4) SY-SAPRL - SAP Release

5) SY-SYSID - System Name

Page 11: Sap Inter Ques1 June2013

6) SY-LANGU - User Logon Language

7) SY-MANDT - Client

8)  SY-UNAME - Logon User Name

9) SY-DATLO - Local Date

10) SY-DATUM - Server Date

11) SY-TIMLO - Local Time

12) SY-UZEIT - Server Time

13) SY-DYNNR - Screen Number

14) SY-REPID - Current ABAP program

15) SY-TCODE - Transaction Code

16) SY-ULINE - Horizontal Line

17) SY-VLINE - Vertical Line

18) SY-INDEX - Number of current loop Pass

19) SY-TABIX - Current line of internal table

20) SY-DBCNT - Number of table entries processed

21) SY-SUBRC - Return Code

22) SY-UCOMM - Function Code

23) SY-LINCT - Page Length of list

24) SY-LINNO - Current Line

25) SY-PAGNO - Current Page Number

26) SY-LSIND - Index of List

27) SY-MSGID - Message Class

28) SY-MSGNO - Message Number

29) SY-MSGTY - Message Type

Page 12: Sap Inter Ques1 June2013

30) SY-SPONO - Spool number during printing

36) What is the difference between Primary key and Unique Key?

Ans Primary Key – It can accepts 0 value and cannot be NULL.

Unique Key – It can be NULL.

37) What is the transaction code for Table maintenance?

Ans SM30

38) If u are using Logical Databases how will u modify the selection-screen elements?

Ans Select-options : dname for deptt-dname.

39) What is an RFC?

Ans Remote Function Call

40) If u are using RFC and passing values to a remote system how does it work?

Ans

41) What are the events in Screen Programming?

Ans There are two events in Screen Programming:

1. PBO (Process Before Output) – Before the screen is displayed, the PBO event is processed.2. PAI (Process After Input) – When the user interacts with the screen, the PAI event is processed.3. POH (Process On Help) - are triggered when the user requests field help (F1). You can program the appropriate coding in the corresponding event blocks. At the end of processing, the system carries on processing the current screen.4. POV (Process On Value) - are triggered when the user requests possible values help (F4). You can program the appropriate coding in the corresponding event blocks. At the end of processing, the system carries on processing the current screen.

42) What is the significance of HIDE?

Ans Its stores the click value and display the related record in the secondary list.

43) Where do u code the HIDE statement?

Page 13: Sap Inter Ques1 June2013

Ans In a LOOP statement

44) Types of BDC’s?

Ans There are two types of BDC’s:

1) Transaction Method

2) Session Method

45) Advantages & Disadvantages of different types of BDC’s?

Ans Transaction Method:

1) It is faster than session method.

2) While executing, it starts from starting.

Session Method:

1) It is slower than transaction method.

2) While executing, it does not start from starting.

46) What are the events used in Interactive Reports.

Ans There are three events of Interactive Reports:

I. At PF(nn)

II. At line-selection

III. At user-command

47) What is an RDBMS?

Ans RDBMS – Relational Database Management System. It helps to create relationship between two or more table.

48) What standards u use to follow while coding ABAP programs?

Ans

49) What will you code in START-OF-SELECTION & END-OF-SELECTON & why?

Ans START-OF-SELECTION

Page 14: Sap Inter Ques1 June2013

SELECT * FROM DEPTT INTO CORRESPONDING FIELDS OF ITAB

WHERE DEPTNO IN DEPTNO.

APPEND ITAB.

ENDSELECT.

LOOP AT ITAB.

WRITE : / 10 ITAB-DEPTNO.

HIDE : ITAB-DEPTNO.

ENDLOOP.

END-OF-SELECTION

50) What are joins and different types joins?

Ans There are four types of Joins:

1) Self Join

2) Inner Join

3) Outer Join

4) Equi Join

51) Which is the default join?

Ans

52) How do u display a data in a Detail List?

Ans By using two statements:

1) Top-of-page during line-selection

2) At line-selection

53) What are the types of windows in SAP Script?

Ans There are five Standard Layouts in SAP Script:

1) Page

Page 15: Sap Inter Ques1 June2013

2) Window

3) Page Window

4) Paragraph Format

5) Character Format

54) What are the function modules used in a SAP Script driver program?

Ans There are three functions used in SAP Script:

1) OPEN_FORM

2) WRITE_FORM

3) CLOSE_FORM

55) What are Extracts?

Ans Extracts are dynamic sequential datasets in which different lines can have different structures. We can access the individual records in an extract dataset using a LOOP.

56) How would u go about improving the performance of a Program, which selects data from MSEG & MKPF?

Ans

57) How does System work in case of an Interactive Report?

Ans

58) What is LUW?

Ans Logical Unit of Work

59) Different types of LUWs. What r they?

Ans Two types of LUW are:

1) DB LUW - A database LUW is the mechanism used by the database to ensure that its data is always consistent. A database LUW is an inseparable sequence of database operations that ends with a database commit. The database LUW is either fully executed by the database system or not at all. Once a database LUW has been successfully executed, the database will be in a consistent state. If an error occurs within a database LUW, all of the database changes since the beginning of the database LUW are reversed. This leaves the database in the

Page 16: Sap Inter Ques1 June2013

state it had before the transaction started.

2) SAP LUW - A logical unit consisting of dialog steps, whose changes are written to the database in a single database LUW is called an SAP LUW. Unlike a database LUW, an SAP LUW can span several dialog steps, and be executed using a series of different work processes.

60) What is First event triggered in program?

Ans

61) What are various Joins? What is right outer join?

Ans

62) How do u find out whether a file exits on the presentation server?

Ans eps_get_directory_listing for directory

63) Systems fields used for Interactive Lists AND Lists

Ans Interactive System Fields: SY-LSIND, SY-CPAGE, SY-LILLI, SY-LISEL, SY-LISTI,

SY-LSTAT, SY-STACO, SY-STARO

Lists: SY-COLNO, SY-LINCT, SY-LINNO, SY-LINSZ, SY-PAGNO,

SY-TVAR0…..SY-TVAR9, SY-WTITL

64) Logo in SAP Script?

Ans RSTXLDMC OR

Steps for making and inserting Logo in SAP Script:

First Procedure:

1) Draw the picture

2) Save it

3) /nSE78

4) Write name & Choose Color

5) Click on Import

Page 17: Sap Inter Ques1 June2013

6) Browse picture

7) Enter

Second Procedure

1) /nSE71

2) Insert

3) Graphics

4) Click on stored on document server

5) Execute

6) Choose name of BMAP

65) What are the difference between call screen and leave screen?

Ans Call Screen: Calling a single screen is a special case of embedding a screen sequence. If you want to prevent the called screen from covering the current screen completely, you can use the CALL SCREEN statement with the STARTING AT and ENDING AT

CALL SCREEN 1000.

CALL SCREEN 1000 STARTING AT 10 10 ENDING AT 20 20.

LEAVE SCREEN statement ends the current screen and calls the subsequent screen.

LEAVE SCREEN.

LEAVE TO SCREEN 2000.

66) If internal table used in for all entries in empty then what happens

Ans No, records will be displayed.

67) If I forgot some command in SAP Script e.g.: suppress zero display - How to do find it?

Ans Suppressing of entire screens is possible with this command. This command allows us to perform screen processing “in the background”. Suppressing screens is useful when we are branching to list-mode from a transaction dialog step.

Page 18: Sap Inter Ques1 June2013

68) How to write a BDC - how do u go about it?

Ans Steps for writing BDC

1) /nSE38

2) Declare Tables, Data (for ITAB) and Data (for BDCITAB)

3) Call function ‘Upload’.

4) Write code for the First Screen, Radio Button, Filename, Change Button, Second Screen, Utilities (Create Entries), Third Screen and Save.

5) Call transaction ‘SE11’ using BDCITAB mode ‘A’.

6) Save, Check Errors, Activate and Execute.

69) What is Performance tuning?

Ans

70) Define Documentation.

Ans

71) Brief about Testing of programs.

Ans

72) How do u move on to the next screen in interactive reporting?

Ans Write code of the following:

1) Top-of-Page during line-selection

2) At line-selection

73) Create any functions? How to go about it?

Ans Steps for creating the Functions:

First Procedure:

1) /nSE37

2) Goto

Page 19: Sap Inter Ques1 June2013

3) Function Group (FG)

4) Create Group

5) Name of FG (ZREKHA_FG)

6) Short Text

7) Save

8)  Local Object

Second Procedure

1) Environment

2) Inactive Object

3) Function Group (ZREKHA_FG)

4) Activate

5) Back

Third Procedure

1) Name of Function Module (ZREKHA_FM)

2) Create

3) Write FG Name (ZREKHA_FG)

4) Short Text

5) Save

Fourth Step:

Call function ‘ZREKHA_FM’.

74) Advanced topics?

Ans

75) Function modules used in F4 help.

Ans There are two types of function modules used in F4 help:

Page 20: Sap Inter Ques1 June2013

1) F4IF_FIELD_VALUE_REQUEST

2) F4IF_INT_TABLE_VALUE_REQUEST

76) Work most on which module: Name a few tables.

Ans Sales & Distribution Module

1) Sales Document: Item Data – VBAP

2) Sales Document: Partner – VBPA

3) Sales Document: Header Data – VBAK

4) Sales Document Flow – VBFA

5) Sales Document: Delivery Item Data - LIPS

6) Customer Master – KNA1

7) Material Data – MARA

8)  Conditions (Transaction Data) - KONV

77) System Table used

Ans

1) Sales Document: Item Data – VBAP

2) Sales Document: Partner – VBPA

3) Sales Document: Header Data – VBAK

4) Sales Document Flow – VBFA

5) Sales Document: Delivery Item Data - LIPS

6) Customer Master – KNA1

7) Material Data – MARA

8)  Conditions (Transaction Data) - KONV

78) From a table how do u find whether a material is used in another material BOM?

Page 21: Sap Inter Ques1 June2013

Ans

79) What is read line?

Ans READ LINE and READ CURRENT LINE – These statements are used to read data from the lines of existing list levels. These statements are closely connected to the HIDE technique.

80) How u used logical database? How is data transferred to program? Corresponding statement in LDB.

Ans

81) How do u suppress fields on selection screen generated by LDB?

Ans

82) Can there be more than 1 main window in SAP Script?

Ans No, there cannot be more than 1 main window in SAP Script because in WRITE_FOR

1. Can we write the code both call transaction and session method in single program?

Ans. Yes it is possible to write call transaction and session in one program.

2. Which BDC you prefer?

Ans. If we want to transfer large amount of data and when we need to use more than one transaction code we prefer session method. For small or less amount of data and for single transaction use call transaction.

(This is more genric answer but you can add more on to this if you have worked on  BDC)

3. When u prefer LSMW?

Ans. When we need to update medium amount of data we use LSMW. LSMW is also used when the person like functional consultant has less programming language.

5. Difference between .include and  .append?

Page 22: Sap Inter Ques1 June2013

Ans.

Include structure allows to add one or more structure into structure or table.Also placed positioning anywhere. Upto 6 include structure can be used in a table.

Append structure can be placed only at the end of a structure or table which also stops further insertion of fields.Only one append structure can be used

6. Preformance techniques

Ans.

1. The sequence of fields must be same as per database table

2. During writing select query write all fields in sequence as per database table.

3. Never write select statements inside loop….endloop.

4. Use st05 SQL trace, se30 run time analysis, code inspector, slin,etc.

5. Use select single * statement instead of select *

6. Always use primary key

7. Use binary search but before using binary search sort that table.

7. How to debug sapscripts ?

Ans.

Two ways to debug sapscript . first way is goto SE 71 and from menu bar select Utilities->activate debugger .then goto SE38 execute the print program ,it automatically goes to debugging mode …..the other way is , run the program RSTXDBUG in se 38 . execute it . a message will show that debugger is activated .now open the print program in se 38 …u vll notice that the print prgm is automatically diverted to debugging mode.

8. What is partner selection?

Ans. This concept is mainly used in IDOC where u select the partner profile using Tcode We20 .with  Tcode SM59 you create RFC(remote function call) to create communication link to a remote system.

10. What is occurs in internal table?

Ans. Occurs addition to the Declaration will give initial size to that table.occur statement allocates 8kb of memory to the internal table.

Page 23: Sap Inter Ques1 June2013

11. What is page window?

Ans : page window is nothing but a container of a page ,which uniquely identifies a set of data …for example while creating invoice …we create logo window , billing document header window , customer window , terms and condition window etc …

12. What is the difference between scrolling a table horizontally and vertically..??

Ans: In table control when you scroll a table vertically presentation server needs to call application server to fetch the next record and display in the table while in case of horizontal scroll there is no need to call application server.

13. What are Field Groups?

Ans: A group that combines several fields fewer than one name, at runtime, the INSERT command is used to define which data fields are assigned to which field group are called Field Groups. It should always be a HEADER field group that defines how the extracted data will be sorted; the fields grouped under the HEADER field group sort the data.

14. List the events in ABAP/4 Language?

Ans: The events in ABAP/4 are load of program ,Initialization, Selection Screen, Start of Selection, End of Selection, Top of page, Line selection, User command, End, First.

15.How the values will be passed to RFC Function module PassbyValue or Passbyreference?

Ans: always Pass by Value.

RFC is Remote Function call so it can’t access the values with Pass by reference.

16. Buffering concept usage?

Ans: There are three type of buffer

1 single record

2 generic buffer

3 full buffer

Buffering is use for improve performance. it improves performance  10 to 100 times more

17. Select up to 1 row and select single difference ?

Page 24: Sap Inter Ques1 June2013

Ans:  Select single fetches first matching record. If more than one matching records are there then only the first matching record will be considered other records will not be taken into account. Where as select up to 1 rows will fetch all the matching records from the database.(Again it will assign only One Record to the internal table/Work area)

18. What are the different buffering methods?

There are two different buffering methods

The system ensures that data transfer between the R/3 System and the database system is as efficient as possible. To do this, it uses the following techniques:

Table buffering: The program accesses data from the buffer of the application server.

Database request buffering: Individual database entries are not read or passed to the database until required by an OPEN SQL statement.

19. Different types of locks?

v  Read lock (shared lock)

Protects read access to an object. The read lock allows other transactions read access but not write access to the locked area of the table.

v  o Write lock (exclusive lock)

Protects write access to an object. The write lock allows other transactions neither read nor write access to the locked area of the table.

v  o Enhanced write lock (exclusive lock without cumulation)

Works like a write lock except that the enhanced write lock also protects from further accesses from the same transaction.

20. CHAIN END CHAIN?

Ans: Chain and end chain are used for multiple field validation in Module pool programming .It is written inside the screen flow logic.

21.How to Debug RFC Function module?

Ans:

SE38 –> Utilities –> Settings –> ABAP Editor –> Debugging

Activate the external debugging and choose the New Debugger option in ABAP debugger.

Page 25: Sap Inter Ques1 June2013

Go to the particular place in the code and put break point, pop will appear then choose the HTTP break point.

If you are triggering the RFC from SAP portal make sure that both the user ID should be same

If the users are different then provide the XI/Portal User ID in the users field.

22.Why sapscripts are client dependent and smartforms are client independent.?

Ans-: Smartforms create its own function module so it doesn’t need to transport the request through SCC1.As all the Development Object are stored in client independent tables. Whereas Script doesn’t generate  any function module while executing so we need to transport the request number through SCC1.Sap script is stroed in side the client depended table as a TEXT.so sapscripts are client dependent and smartforms are client independent.

23. Difference between user exit and BADIs?

Ans: User exit is for single implementation and it is procedural approach while BADIs are for multiple implementation and object oriented approach.

Multiple implementation means Reusability… because we use OOps Concepts for BADI.

24. Control break events in ABAP:-

1. AT-FIRST: This is used when we want to execute the statements before records are processed.

2. AT-LAST: This event is used when we want to execute the statements after all records are processed.

3. AT-NEW: This event is used when we want to execute the statement before group of records are processed.

4. AT-END: This event is used when we want to execute the statements after processing of group of records.

25.I am uploading 100 records out of which say 59th record has error so what will happen if i am using synchronous or asynchronous method of BDC? Can we update the database using local update mode how?

26. Suppose i am writing following code then what will be output?

LOAD-OF-PROGRAM.WRITE:/”HELLO”.Ans:  HELLO

Page 26: Sap Inter Ques1 June2013

(Explain the importance of LOAD-OF-PROGRAM Event.If you dont know Tell the interviewer as this event is used in such cases when you want to clear sum buffers or something Before calling that Program)

27. What is TMG?

Ans. TMG stands for Table Maintenance generator. It is a tool available in abap by which we can add or delete multiple records at a time and it is executed or triggered by the transaction code SM30.

28. Difference between select option and ranges ?

Ans. The main difference between select option and ranges is that ranges implicitly or automatically creates internal table with fields like OPTION,LOW,HIGH,SIGN,etc . Where as in case of select option we have to explicitly create internal table.

When u declares a select options it will implicitly declare an internal table (ranges) for you.

While using RANGES syntax u can declare internal table explicitly.

The only need of declaring ranges is when you r not taking input from the user but you want make limit based selection at that time it will be use full e.g. SELECT ** from ** where MATNR in val_range.

here u can use select-option or ranges : val_range.

29. is it possible to bring select option in module pool screens?

Ans.Create a SELECT-OPTIONS in module pool screen using two methods as shown.

Method 1:—-

a) Create a subscreen area in your screen layout where you want to create the select options.

b) In the top include of your module pool program declare a selection screen as a subscreen e.g.

SELECTION-SCREEN BEGIN OF SCREEN 100 AS SUBSCREEN.select-options s_matnr for mara-matnr. SELECTION-SCREEN END OF SCREEN.

c) In the PBO and PAI of the main screen where the select options needs to be created do a call subscreen of the above screen (100).

CALL SUBCREEN sub_area INCLUDING <program> <screen>

Page 27: Sap Inter Ques1 June2013

This CALL SUBSCREEN statement is necessary for transport of values between screen and program.

Note: All validations of the selection screen fields e.g. the s_matnr field created above should be done in selection screen events like AT SELECTION-SCREEN etc and not in PAI. These selection screen validations etc should be done in the top include only.

Method 2:——-

a) Create 2 separate fields in your screen layout – one for the low value and one for the high value. Insert an icon beside the high value which will call the multiple selections popup screen on user command. Use function module COMPLEX_SELECTIONS_DIALOG to achieve this.

continued ……

struc_tab_and_field-fieldname = con_cust. ” ‘KUNNR’struc_tab_and_field-tablename = con_kna1. ” ‘KNA1′.CALL FUNCTION ‘COMPLEX_SELECTIONS_DIALOG’ EXPORTING*TITLE = ‘ ‘text = g_titl1 ” ‘Customers’tab_and_field = struc_tab_and_fieldTABLES RANGE = rng_kunnrEXCEPTIONSNO_RANGE_TAB = 1CANCELLED = 2INTERNAL_ERROR = 3INVALID_FIELDNAME = 4OTHERS = 5.IF NOT rng_kunnr[] IS INITIAL.* Read the very first entry of the range table and pass it to* dynpro screen field*READ TABLE rng_kunnr INDEX 1.IF sy-subrc = 0.g_cust = rng_kunnr-low.ENDIF.ENDIF.

You can use the return table rng_kunnr to populate your own internal range table with the values entered by the user. Basically here you are just simulating the work of a select-options parameter by module pool screen elements.

30.how we can retrive data using secondary index.explain with simple example

Ans:  First create secondary indexes on required fields of a particular database table.

Page 28: Sap Inter Ques1 June2013

We can create one primary index and 15 secondary indexes.Once the respective secondary indexes are created write select queries and within select queries specify secondary indexes field name with where clause.

31.How can we handle table control in BDC?

Ans.We can handle table control using line index

Line index indicates which line of Table control is to be use for BDC transaction

Ex -

perform bdc_field using ‘RC29K-AUSKZ(01)’

Indicates 1st line of table control is going to be used for transaction which is Line index of Table Control

32. If i want to execute a BDC program only in background not in foreground is there any option for this?

Ans.The sm37 transaction can be used for running a program in the background. Also in the session method while processing the session you can specify the processing type as background or foreground.

33.How Can We upload a text file having Delimiters in to Legacy System

Ans.For up loading text file we use the pre-defined FM gui_upload. in that FM we have the parameter has_field_seperator for that we assign the default delimiter ‘x’.

HAS_FIELD_SEPERATOR ‘X’

‘X’ can provide the Whatever delimiter we used in flat file for separation.

34. What is the land scape in sap.

Ans. In every organisation sap landscape involves three servers viz, Development server, Quality server and Production server. Whatever new development we do as per clients requirement is done in development server. Later to test the developed object we move it to quality server for testing and finally once everything goes clear then the object is moved to production server ,production server data is ready for final business use.

35. Workbench request are client dependent or client independent

Ans. Workbench request are client independent.

Page 29: Sap Inter Ques1 June2013

(Common Man Workbench request holds the Program , FM etc…. How it can be Client Dependent!!!!)

36. Tell me about workbench request and customization requests.

Ans.Workbench (ABAP Dev) request is client independent when you import it into one system it reflact it in all client in same system, but customized request has to import in that client perticular client where it is created, actually it is client dependent.

Other   Interview questions…

SAP SCRIPTS & FORMS

1. Can we write the code/program inside sap script?

2. How will u create sapscripts & smartforms in multiple language?

3.How to execute sap script & smart forms in Background?

4.How to do total & subtotal in scripts & forms?

=================================================

DATA DICTIONARY

1.Apart from .include & .append how will u do table enhancement?

2.what r the events of table maintainence generator?

3.what will happen if i use projection view and maintainence view together?

4. I created ZEMP table now i want to add more data but prev. data should not disturb how can i do this?

=====================================================

REPORTS

1.How will u print footers in alv report?

2.How will u edit fields from output list of alv?

====================================================

BDC

Page 30: Sap Inter Ques1 June2013

1.what r the fields u took during recording for mmo1,me21n?

2.If u want to do bdc for xd01 explain me how will be the flow?

=================================================

user exits

1.what r enhancement points?

2.How to write customer exits?

3.what is routine? how it is different from user exits?

1.sapscript and smartforms

Sap script is client dependent and smart form is client independent. Smartforms has Only 1 main window while Sap script has 99 main windows

You can not print labels using smart forms

2.BDC and LSMW

In BDC we have to take care of field mapping whereas field mapping is taken care by sap in lsmw.

BDC is mostly used for customised data upload while LSMW is used for uploading Master data.

In BDC we need to write large code but in LSMW small coding is needed.

3. BADI and BAPI

BADI is business add ins, it is used to customize the standard business flow BAPI is Business application programming interface. It is nothing but Remote enabled

function module which can be called from outside the SAP System.

4.user exit and customer exit

User exit is an include program given by SAP in that you can write your code , It needs Access key from SAP while key is not required in case of customer exit

5. Select single and select up to one row

Page 31: Sap Inter Ques1 June2013

Select single will fetch only one record while select up to n row. Will fetch n rows from database

6. Normal (Classical) report and ALV report

To display the output in classical report you use WRITE Statement. To display the output in ALV we have different function modules and class like

REUSE_ALV_GRID_DISPLAY , REUSE_ALV_LIST_DISPLAY and CL_SALV_TABLE.

If you run the classical report in background after JOB finished you can see it’s output which stored in spool, While in case of ALV you need code extra to store the output as it will not generate the spool.

7. ALV list display and ALV grid display

You cannot retrieve the output for the report which is displayed using ALV GRID Display.As spool Request will not be created for the same. While in case of list display Report out put will be there in spool request.

8. Classical and drill down report

In classical report user cannot interact with report whereas in drill down report user can interact with report.

Drill down facility is not provided in classical report while in drill down it is provided.

If they ask you in detail then tell the interviewer that interact with the report means in drill down report we have one basic list and 20 secondary lists so we can directly go to 5th list or 10th list as per our requirement similarly we can come back to any list. Drill down means showing data in basic list first and when we double click on any field we get summarised list. NOTE:- to go to next list in drill down report use following syntax SY-LSIND = < list number> example: to go to 15th list SY-LSIND = 15 to come to 5th list from 15th list use F3 KEY OR PRESS BACK BUTTON

9. BAPI and RFC function module

BAPI is nothing but remote enabled function module BAPI is provided as a method of business objects

10.sap 4.7 and ECC 6.0

SAP 4.7 is based on Web AS ECC 6.0 is based of Netweaver 7.0.

11. get cursor and hide in interactive report

Get cursor will provide the location cursor position in the report

Page 32: Sap Inter Ques1 June2013

While hide is use to pass the data from basic list to secondary list

12.normal function module and RFC

You cannot call normal function module from outside the current system while RFC function module can be called from outside the SAP system.

13. Subroutine and function modules.

Subroutine is local to the program while function module is global. To call subroutine from outside its main program you need to write its main program

name in the bracket

14.At selection screen and At selection screen output.

At selection screen output is called first All dynamic commands and screen modification is done in AT selection screen output.

15.direct input and batch input

The basic difference is validation is not done in direct input by pre defined function while in batch input it is coved.

16.synchronous and asynchronous in BDC

Synchronous mode will wait until the BDC session gets over while asynchronous mode will not wait for that

17.at selection screen and at selection on field name

At selection screen is used to validate the whole screen elements while at selection field is used to validate the particular field.

When you display the error message in at selection on field the focus will be on that particular field while in case of At selection screen the focus will not be on any particular field.

18. PBO and PAI event in module pool

Process Before Output and Process after input. PBO will be called before the screen is displayed to the user while process after input is

called once user interact with screen.

19. Stop , check and exit

If you use the STOP statement within an event block, the system stops processing the block Immediately.

Page 33: Sap Inter Ques1 June2013

If you use the EXIT statement within an event block but not in a loop, the system stops Processing the block immediately

If you use the CHECK <expr> statement within an event block but not within a loop, and the Condition <expr> is not fulfilled, the system exits the processing block immediately. <expr> can be any logical expression or the name of a selection table. If you specify a selection table and the contents of the corresponding table work are do.

20.free and refresh in internal table

You can use FREE to initialize an internal table (along with header line ) and release its memory space.

Page 34: Sap Inter Ques1 June2013

REFRESH will only initialize an internal table (along with header line)

21.clear and delete.

The major difference is clear is used with internal table while delete is used with database table.

22. collect and sum

COLLECT <line> INTO <itab>. The statement first checks whether the internal table contains an entry with the same key. If not,it acts like INSERT. If there is already a table entry with the same key, COLLECT does not inserta new line. Instead, it adds the values from the numeric fields of the work area <line> to thevalues in the corresponding fields of the existing table entry.

SUM.Can only be used in loops through internal tables. Calculates the sums of the numeric fields in alllines of the current control level and writes the results to the corresponding fields in the workarea.

23. call transaction and session method

Call transaction is Synchronous Processing while session (classical) method is Asynchronous Processing

In call transaction we can update the database both synchronously and asynchronously. We can specify the mode in the program. While in session method it is Synchronous Database update.

In call transaction No batch input processing log is maintained while in session method details log is maintained.

Call Transaction method is faster than the session method.

24. at first and at last control break event

As the name suggest AT FIRST executed for the first time while AT LAST executed in last.

25. Enhancement point and Enhancement Section

Both the enhancement-point and section are available for you to change standard SAP code. Difference is in fact that you use Enhancement-point to add ABAP code to standard SAP and enhancement-section to replace/extend standard SAP code. 

26.end of page and top of page

Top of page trigger when report encounter the first write, skip or new-line statements. End of page trigger when page size is over or report display gets over.

Page 35: Sap Inter Ques1 June2013

27. Table and structure

Table has physical definition into the underline database while structure does exist physically in the data base.

28. table and views

Table has data init while view does not contain data in it. Both exist in the data base. when u run the view it queries the database and gives the respective data.

29.inner joins and for all entries

Inner join joins the table at database level whereas For..All..Entries joins the table at application level.

In For..All..Entries when the condition gets satisfied data is fetched in one single shot from database table whereas in inner join data is fetched iteration by iteration

It is always good programming practice to join tables at application level because if we join tables at database level then there might be performance issue

30. Transparent table pool table and cluster table

Transparent Table : Exists with the same structure both in the dictionary and database exactly with same data and fields. it’s to store transaction data. It’s one to one Relation table

Pool tables : These are logical tables must be assigned to a table pool when they are defined. Its use to store control data. its many to one relation table

Clustered tables : these also logical tables and must be assigned to table cluster when they are defined. It’s also used to store control data, temporary data or text ex., documentation. It’s also many to one relation table.

31. Top of page and top of page during line selection

Top of page is triggered for the basic list while top of page at line selection triggers at secondary list.

32. Start_form and End_form in sap script

start_form function module is called if we want to use different forms with similar characteristics in a single spool request ,it must be closed by END_FORM function module

33. open dataset and close dataset

Open dataset is use to read / write file into application server while close dataset is use to close that file.

Page 36: Sap Inter Ques1 June2013

34. data element and domains

Domain gives technical details like length , decimal etc..while data elements gives description and business details

35. set screen and call screen

Set screen <no> set the next screen value and temporarily override the next screen value in screen attribute. While call screen <no> jump to the screen specified in <no>.

36. Internal Session and External Session

External session is nothing but the window you have opened in your screen .By Default you can open 6 external sessions( 6 windows = you can increase it via basis’s setting). Internal session is created when you call any Functional module or any other task in your program. counts for internal sessions are 9.

37. Elementary and collective search help

An Elementary Search help defines the flow of a standard input help. It is composed of a selection method that defines where to get the data that will make up the hit list, An interface consisting of search help parameters that define the exchange of data between the screen and the selection method and a dialog type that controls how the hit list will be displayed.

A Collective Search help is a combination of several elementary search helps giving the user a different search paths. The interface parameters of the elementary search help are assigned to the parameters of the collective search.

38. What is the difference between Clustered Tables and Pooled Tables?

A pooled table is used to combine several logical tables in the ABAP/4 dictionary. Pooled tables are logical tables that must be assigned to a table pool when they are defined.

Cluster table are logical tables that must be assigned to a table cluster when they are defined.

Cluster table can be used to store control data they can also used to store temporary data or text such as documentation.

39. user exits and customer exit.

User exit is sap defined includes so to modify it we need key from SAP.while customer exit like function exit , screen exit we don’t need any key.

40. sapscript smart forms and adobe forms

Sapscript is client dependent whereas smartform is client independent.

Page 37: Sap Inter Ques1 June2013

Main window is compulsory in scripts whereas main window not compulsory in form.

Smartform output can be seen in web while in scripts it is not possible.

smartform generates function module while scripts dont generate function module.

41. screen and subscreens in module pool.

Screen has it’s own gui status while subscreen does not have any gui status.Subscreens are part of main screen.

42. standard table and hashed tables.

Standard table can be accessed by key as well as index while You can only access hashed tables by specifying the key. The system has its own hash algorithm for managing the table.

Sap Reports Interview Questions and Answers

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 *lt;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 are user exits? What are customer exits? User exits and customer exits are the same thing. Both are used to give the customer the chance to influence the outcome of a process(-step) in some way, without having to change the standard SAP software. For example: if an order is entered in the system, availability checks, credit checks etc. could be performed by the system but just before writing the order to the database, the program runs a user exit. In this user exit, your code could change some fields in the order or write an entry in a table that you created for some reason.

What is the difference between start_form and open_form in scripts? Why is it necessary to close a form always once it is opened? Answer1:

Page 38: Sap Inter Ques1 June2013

strat_form using this we can open many layoutses open_form using this we can open the layout performance will be high

Answer2:Open_form -- is used to initialize the spool request. Start_form-- is used to initialize the layout.

What is difference between ON Change of and At New Field ? Select Single * from and select Upto 1 rows

At new - on change of difference: In case if you want calculate sub totals for same values in a field you can use the atnew statement.ie: For example in a table sflight, there are 2 fields carrid ( airline id) and seatsmax( seat available). In case if you want calculate the total number of seats available for each carrrid you can sort the table first and using the at new and sum you can claculate the total seats for each carrid. Atnew will be triggered whenever there is a change in the carrid and the total seats will be returned for each carrid. In the same scenario if you use onchange of it will not return the total seats for each carrid, instead it will return the total seat count for the entire table( ie: for all the carrids in the table. Another diffrence is atnew can be used only between loop and end loop whereas on change of can also be used in select- endselect , do -enddo. Another diffrence is while using atnew in case if you code any write statements between atnew and end at the value for the numeric fields will be returned as 0 and that of no numeric fields will be returned as *(asteriks). But in on change of the orginal values will be returned. Select single * and select upto 1 row diffrence. The select single * from stmt selects only one row form the database table and puts it in to the work area(internal table). The select upto n(where n stands for a integer number) rows stmt selects all the rows from the database table but writes only the specified number of rows specified by the n into the internal table. If its given as upto 1 rows only 1 row is written in to the internal table.

When you create sales report, What you can see in that report ? What are those field names or data element names?

 vbak-auart, "ORDER TYPEvbak-audat, "DOCUMENT DATEvbak-kunnr, "CUSTOMERvbak-bstnk, "PURCHASEORDERNOvbak-submi, "collective novbrp-posnr, "ITEMvbrp-matnr, "MATERIAL NUMBERvbrp-arktx, "DESCRIPTIONvbrp-fkimg, "ORDER QTYvbrp-vkbur, "SALESOFFICEvbrp-aubel, "SALES DOCUMENTvbrk-netwr, "NETPRICE

Page 39: Sap Inter Ques1 June2013

vbrk-vbeln, "BILLINGDOCNOvbrk-knumv, "DOC.CONDITIONkna1-name1, "CUSTOMERNAMEvbrp-werks, "PLANTvbrk-kunrg, "PAYERkna1-name1, "PAYER NAMEvbpa-kunnr, "EMPLOYEENOvbrk-netwr, "DISCOUNTvbrk-netwr,"NETAMTvbrk-netwr,"INVAMTvbrk-fkart, "billing typevbrk-netwr, "CSTkonv-kbetr, "CST PERvbrk-netwr, "LSTkonv-kbetr, "LST PERvbrk-netwr, "EDkonv-kbetr, "ED PERvbrk-netwr, "Ecskonv-kbetr, "Ecs PERvbrk-netwr, "SURCHARGEvbrk-fkdat, "BILLINGDATEkna1-name1, "EMPLOYEENAMEvbak-bstdk, "PODATElikp-bolnr, "Bill Of Ladinglikp-traty, "Means of Transport Typelikp-traid, "Means of Transport IDvbpa-kunnr, "Bill To Partykna1-name1, "Bill To Party Namevbrk-netwr, "Net Amount Basic Amount - Discount

How to assign multiple transaction codes in a session method to BDC_Insert function module? Call function ' BDC_Insert' exporting tr. code = ' enter tr.code1 here' table = 'give an internal table related totr.code1 here' call function 'BDC_INSERT' exporting tr.code = ' enter 2nd tr code' tables = ' 2nd internal table'

“Check” and “Continue”. What is the difference? Check statement, checks the condition with in a loop and if it satisfies the condition, the control moves to next statement in the loop. Otherwise, it terminates the loop.

Continue statement, acts like goto statement. If the condition is true, it processes the remaining statements and if the condition is false, then the control moves to the top of

Page 40: Sap Inter Ques1 June2013

loop.At-Line selection, At user-command etc..,

In at line-selection system defined fcode will be generated In at user-command we need to define the fcode and fkey manually then only it will triggers.

“Exit” and “Stop”. What is the difference? exit statments is exit the current loop. and moving to next loop but stop statement move to end of selection. it's not check all other loops.

What is the reserve command? Answer1:Reverse Command :Reverse N Lines : if there is not enough space left on the current page for atleast n lines it starts a new page

Answer2:RESERVEIf insufficient space is there for listing output reserve statement encounters NEW-PAGE.But before going to new page it processes END-OF-PAGE.

What are event keywords in reports? Answer1:Events keywords in Reports areFor Classical Reports,1.Initialization2. At line-selection 3. Start-of-selection 4.Top-of-page 5. At user-command 6.End-of-selection 7. End-of-page 8.At PfnFor Interactive Reports,9.At line-selection 10. Top-of-page during line selectionFor LDB (Logical DataBase) Reports,10. get 11.put 12. get table

Answer2:1. Initialization2. At line-selection3. Start-of-selection4.Top-of-page5. Top-of -page during at line-selection6. At PF7. At user-command8.End-of-selection9. End-of-page

Page 41: Sap Inter Ques1 June2013

ow can validate input values in selection screen and which event was fired?Answer1:We can Validate Selection Screen With the Help of the Following Events, the Event Follows the Same hierachy.

AT SELECTION-SCREEN ONAT SELECTION-SCREEN ON BLOCKAT SELECTION-SCREEN OUTPUTAT SELECTION-SCREEN.

Answer2:At selection-screen onselect stmt ------------------ where = .if sy-subrc = 0.validation success for LOw value in selection screenAt selection-screen onselect stmt-------------------- where =if sy-subrc <> 0.validation failure on high value in the selection field.elsesuccess.endif

BDC Transaction code? Transaction code for bdc :SHDB

How to navigate basic list to secondary list? We can Navigate from basic list to secondary list with the help the event called AT LINE-SELECTION. for every Secondary List the System Field SY-LSIND increases by 1. So there will be Totally 21 list possible in SAP.

One Basic List 20 Secondary List.

Which is the First character of creating LockObject? LockObjects always starts with character 'E'.

What is the Difference between Data Element and Domain? Answer1:Domain: Defines the attributes such as length,type and possible value range. Data element; An intermediate object between domain and table type

Answer2:Domain : technical attributes of dataelement is called domain.Dataelement : Symantic attributes are called dataelement.

How many types of standard SAP Internal Tables?

Page 42: Sap Inter Ques1 June2013

1)standered table2)index table3)hashed table4)sorted table

What is the Difference Between Tablecontrols and Step Loops? Table controls have both horizontal and vertical scrollers and cursor control logic is designed implicitly.Step loops have only horizontal scrollers and cursor control logic is to be designed by the user explicitly.

What are the Events in Dialog Programs? Events in Dialog Programming are:PBO-Process Before OutputPAI-Process AFter InputPOH-Process on Help RequestPOV-Process on Value Request

How many ways you can create Table? User can create a Database table in two ways.

1.Top-to-bottom approach: In this approach, first fields are defined and later domain and data element are defined.2.Bottom-to-top approach: In this approach, first domain and data element are defined and later fields are defined.

What are the Cluster Tables? 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 are function modules in LDB? Function modules in LDB's are

getputget late

What are Difference Between Classical Batch Input and Call Transaction? Answer1:In Batch input many transactions can be executed, where as in Call transcation only one transactioin can be executed. BI is a background process, Ct can be either background or foreground .

Page 43: Sap Inter Ques1 June2013

BI is Synchronous process, Ct is both Asynchronous & Synchronous. BI Sessions cannot be runed parallel. Log file is generated automaticly in BI, errors can be found through BDCMSGCOLL.

Answer2:1.batch input works for multiple applications where as call transactions doen't work 2.batch input has an implicit log file with it. where as call transaction doesn't have 3.batch input has sy-subrc check with the database where as call transaction doesn't have so call transaction is fast.

How can you call the Sessions? using transaction code SM35

Can you call Report in SAP Script? Yes, we can. Just write in Line editor: /:perform f_display_report -------------- ---------- ---------- /:endperform THIS PERFORM WOULD BE DECLARED IN THE PRINT PROGRAMME IN WHICH YOU CAN ALWAYS WRITE STATEMENT SUBMIT REPORT...

How to Upload Logo to Layout Set and what is Program Name? You can also upload a Logo in BMP format - it has to be saved as "%^ Colours if it is a colour Bitmap. If you don't save a colour Bitmap as 256 Colours then it will be uploaded in Black. This can be done in Smart Forms, SAPScript or Transaction SE78

Sap Reports Interview Questions and Answers

What are the SET Parameter and GET Parameter?To use parameter IDs, you need to “set” (store) values in the global memory area and then “get” (retrieve) values from this parameter ID memory area. §IIn the case of an online program, you will “set” values from screen fields and you will “get” these values for screen fields. §YYou can perform this “set/get” function two ways: § Use the ABAP statements “SET PARAMETER ID” and “GET PARAMETER ID”. § Use the field attributes “SPA” and “GPA” . §RRemember that parameter IDs can only be used with ABAP Dictionary fields because parameter IDs are linked to data elements. The appropriate data elements must have a parameter IDs for this “set/get” function to work.

Page 44: Sap Inter Ques1 June2013

What are Text Elements? Text elements makes program easier to maintain program texts in different languages. These are used for maintainig list headers,selectiontexts in programs

What is an Interactive Report? An Interactive report allows the user to participate in retrieving and present data at each level.while classical report doesn't have access to interact

What are Layout set Elements? layout set elements are

1.header 2.peragraph formats 3. character formats 4. windows 5. pages 6.page windows

Distinguish between setscreen and call screen? In the case of setscreen the entire processing of the current screen takes place and then the system branches out to next screen.if u want to branch out to the next screen without processing the current screen then LEAVE SCREEN should be used along with SET SCREEN.

CALL SCREEN is usually used for pop up screens.

What is ABAP Memory and SAP Memory? Answer1;SAP memory is a memory area to which all main sessions within a SAPgui have access. You can use SAP memory either to pass data from one program to another within a session, or to pass data from one session to another. Application programs that use SAP memory must do so using SPA/GPA parameters .

ABAP memory is a memory area that all ABAP programs within the same internal session can access using the EXPORT and IMPORT statements. Data within this area remains intact during a whole sequence of program calls. To pass data to a program which you are calling, the data needs to be placed in ABAP memory before the call is made. The internal session of the called program then replaces that of the calling program. The program called can then read from the ABAP memory.

Answer2;1. SAP memory is for cross-transaction Applications and ABAP/4 memory is transaction-specific.

2. The SAP memory, otherwise known as the global memory, is available to a user during the entire duration of a terminal session. Its contents are retained across transaction boundaries as well as external and internal sessions. The contents of the ABAP/4 memory are retained only during the lifetime of an external session. You can retain or pass data across internal sessions.

3. The SET PARAMETER and GET PARAMETER statements allow you to write to, or read from, the SAP memory. The EXPORT TO MEMORY and IMPORT FROM MEMORY statements allow you to write data to, or read data from, the ABAP memory.

Page 45: Sap Inter Ques1 June2013

Explain Check Table and Value Table ? check tabke works at table level and value table works at domain level. check table is nothing but master table that u will create with valid set of values. value table it provides the list of values and it will automatically proposed as a check table while creating foreing key relationship

How many types of Standard Internal Tables? - STANDARD TABLE: The key is, by default, set to NON-UNIQUE. You may not use the UNIQUE addition.

- SORTED TABLE: Unlike stadard tables, sorted table have no default setting for the uniqueness attribute. If you do not specify either UNIQUE or NON-UNIQUE, the system defines a generic table type, where uniqueness is irrelevant. You can use generic types to specify the type of generic subroutine parameters.

- HASHED TABLE: Hashed tables have no default setting. You must use the UNIQUE addition with hashed tables. You may not use NON-UNIQUE.

What is Refresh in Internal Table? 'Refresh' is the keyworld which clears the contents of an internal table body.

What is the Difference Between Collect and Sum? COLLECT allows you to create unique or summarized datasets. The system first tries to find a table entry corresponding to the table key. The key values are taken either from the header line of the internal table itab, or from the explicitly-specified work area. If the system finds an entry, the numeric fields that are not part of the table key (see ABAP number types) are added to the sum total of the existing entries. If it does not find an entry, the system creates a new entry instead. The way in which the system finds the entries depends on the type of the internal table:

- STANDARD TABLE: The system creates a temporary hash administration for the table to find the entries. This means that the runtime required to find them does not depend on the number of table entries. The administration is temporary, since it is invalidated by operations like DELETE, INSERT, MODIFY, SORT, ...). A subsequent COLLECT is then no longer independent of the table size, because the system has to use a linear search to find entries. For this reason, you should only use COLLECT to fill standard tables.

- SORTED TABLE: The system uses a binary search to find the entries. There is a logarithmic relationship between the number of table entries and the search time.

Page 46: Sap Inter Ques1 June2013

What are the ways of creating Tables? There are two ways to create table 1) top-down approach2) bottom-up approach

What are Function Modules? Answer1:Function modules is a extranal subroutine.we can call it to outside the program.its a mini program. its used for redues the coding,easy to find error.

Answer2:Function modules is like a small program (is not a suboutine because sub-routines are not standalone objects-i.e we cannot execute them alone) which are similar to 'functions' in C.

We can pass the varible and get the return values even with out knowing what is happening in its code.

They are standalone programs-i.e.we can debug and execute them alone unlike subroutines and macros and includes.

What is CAT? "CAT" Computer Aided Test Tool. Used to create test cases for application testing purposes.

Sap Reports Interview Questions and Answers

What is LDB?Logical Database is an ABAP program which retrieves data from various tables Which are interrelated and provides a read only view of the data.

What are the EVENTS in Report Program? What are EVENTS In Interactive Report and Explain? Classical Report Events are LOAD OF PROGRAM.INITIALIZATION. AT SELECTION-SCREEN.START-OF-SELECTION.TOP-OF-PAGE.END-OF-PAGE.END-OF-SELECTION.

Interactive events areAT LINE-SELECTION.AT USER-COMMAND.TOP-OF-PAGE DURING LINE-SELECTION.

Page 47: Sap Inter Ques1 June2013

AT LINE-SELECTION:Allows the user to interact with the lists.AT USER-COMMAND:USed for handling Push buttons.SET PF-STATUS:Provides User Interface.

What are the various techniques of BDC? call transaction session method direct input method

What is SQL Trace? SQL Tracer is a tool used to measure the performance of ABAP program. T.code :st05

What is LUW? It is a span of time during which database records are updated either commit or rollback.

Have you worked with reading and writing data on to files? YES, open dataset <filename> for output. read dataset <filename> from itab. close dataset <filename>.

Have you created tables in SAP? What are client dependent and independent tables? How do you create independent tables? Tables which are having MANDT field is called as client dependent tables. Tables which are not having MANDT field is called as client dependent tables.

Have you used SM30 and SM31 transactions? sm30 is used to view the ' Call Up View Maintenance ' and SM31 is to view the ' Table maintenance ' with

How many dictionary objects are there and list all Available Dictionary Objects are Domains, Viwes, Match Codes, Lock Objects, Structures, Data Elements, Intenal Types.

What is the difference between transparent and non transparent database tables? Transparent tables have 1 - 1 cardinality b/w Data Dictionary and Database, and non transparent ( Cluster and Pooled) tables have Many - 1 cardinality.

Transparent table can access with using OPen & NAtive SQL stmts where as Nontransparent only OPen Sql.

Transparent trables can store Table relevent data and non transparent tables can store system data/ application data based on the transparent tables

What is meant by BDC. How many methods of BDC are there? BDC -> BATCH DATA COMMUNICATION. METHODS OF BDC-> Direct Input method, Batch Input Session method, Call transaction method.

Page 48: Sap Inter Ques1 June2013

What are the difference between table controls and step loops in dialog programming? 1. Function modules use a special screen to define the parameters where as subroutines use the same ABAP/4 editor to define its parameters.2. Tables work area can be commonly shared by calling program and subroutine where as function modules do not share commonly. 3. Calling a function module syntax (Call function.) is different from calling a subroutine syntax (perform….). 4. With raise statement user can exit from a function module where as exit is used in subroutines.

What is ALE, IDOC , EDI , RFC. Explain briefly. ALE: application linking enabling IDOC: intermediatary documents EDI: electronic data interchange RFC: remote function call

What is a binary search? Binary Search is used in internal table for searching the records. its means record searched one by one from top & bottom both side.so its a easy nd fast way to find the record.bt pointer searching is better.

Types of User Exits, what kind of work is done on these exits? File Exit, Menu Exit, Function Exit.

How will you find out where the user exits are available? CMOD : This transaction allows you to create a PROJECT by identifying its ENHANCEMENT(S). After determining all of the ENHANCEMENTS that are part of the PROJECT, you will have to activate the PROJECT. You will still need to code your user-exit; therefore, you may want to wait until this step is completed before activating the PROJECT.

§SMOD : This transaction allows you to create an ENHANCEMENT, which you will include in a PROJECT, by identifying its COMPONENT(S). In the case where SAP has already created an ENHANCEMENT for its pre-defined user-exits, you will not need to use transaction SMOD; instead, you should just use transaction CMOD.

Have you created any transactions? Yes,We can use TC SE93 for creating our own transaction code.

Difference between Table-Controls and Step-loops? Table controls are modified / mproved versions of step loops.in controls we can do,horizontal scrolling,vertical scrolling,scrolling in a perticular field,resize the table,

Page 49: Sap Inter Ques1 June2013

can save the settings for future use,can make selective columns editable,....etcthese things are not possible with step loops.step loops are controlled by loop-endloop statements.

Import and Export ABAP memory is a memory area that all ABAP programs within the same internal session can access using the EXPORT and IMPORT statements. Data within this area remains intact during a whole sequence of program calls. To pass data to a program which you are calling, the data needs to be placed in ABAP memory before the call is made. The internal session of the called program then replaces that of the calling program. The program called can then read from the ABAP memory. If control is then returned to the program which made the initial call, the same process operates in reverse.

How many interactive reports did you write? In an Interactive Report, user can define maximum 20 secondary lists.

What is an “Unpack command” UNPACK field1TO field2 .Unpacks the packed field field1 and places it in the field field2 with leading zeros. If field2 is too short, it is truncated on the left.

ap Abap Interview Questions and AnswersWhat is the difference between collect and sum?SUM.When processing an internal table in a block starting with LOOP and concluded by ENDLOOP , SUM calculates the control totals of all fields of type I , F and P (see also ABAP/4 number types ) and places them in the LOOP output area (header line of the internal table or an explicitly specified work area).

When you use SUM in a LOOP with an explicitly specified output area, this output area must be compatible with the line type of the internal table.When using LOOP to process a sorted extract (see SORT ), the control total of f at the end of the group appears in the field SUM(f) - - if f is type I , F or P .

COLLECT.COLLECT is used to create unique or compressed datsets. The key fields are the default key fields of the internal table itab .

If you use only COLLECT to fill an internal table, COLLECT makes sure that the internal table does not contain two entries with the same default key fields.

If, besides its default key fields, the internal table contains number fields,the contents of these number fields are added together if the internal table already contains an entry with the same key fields.

Page 50: Sap Inter Ques1 June2013

If the default key of an internal table processed with COLLECT is blank, all the values are added up in the first table line.

If you specify wa INTO , the entry to be processed is taken from the explicitly specified work area wa . If not, it comes from the header line of the internal table itab .

After COLLECT , the system field SY-TABIX contains the index of the - existing or new - table entry with default key fields which match those of the entry to be processed.

COLLECT can create unique or compressed datasets and should be used precisely for this purpose. If uniqueness or compression are unimportant, or two values with identical default key field values could not possibly occur in your particular task, you should use APPEND instead. However, for a unique or compressed dataset which is also efficient, COLLECT is the statement to use.

If you process a table with COLLECT , you should also use COLLECT to fill it. Only by doing this can you guarantee that the internal table will actually be unique or compressed, as described above and COLLECT will run very efficiently.

If you use COLLECT with an explicitly specified work area, it must be compatible with the line type of the internal table.

How we format the data before before write statement in report ? We can format the reports output by using the loop events like:

1.at first2.at new3.at lastetc check docu

What is the difference between Table and Template? table is a dynamic and template is a static

When do we use End-of-selection? End-of-selection event are mostly used when we are writing HR-ABAP code. In the HR-ABAP code, data is retrived in the Start-of-selection event and Printing on the list and all will be done in End-of-selection event.

In events start-of-selection is default event. When we have to use this event explicitly? Why? The default event in the ABAP is Start-of-selection.We have to call explicitely this event when you are writing other than ths event , that is when you write AT SELECTION-SCREEN EVENTS OR INITIALIZATION EVENT etc,you have to explicitely mention the Start-of-selection event while you are writing the logic.

Page 51: Sap Inter Ques1 June2013

Before these events called ,all the code you have written come into this default Start-of-selection screen event.

What is the differences between ABAP and OOABAP. In which situation we use OOABAP? OOABAP is used to develop BSP/PCUI applications and also anthing involved object oriented like BADIs, SmartForms..etc.where as ABAP is used to develop traditional programs in R/3.

What is table buffer? Which type of tables used this buffer? buffer is nothing but a memory area. table is buffered means that table information is available on application server. when you call data from database table it will come from application server.

transperent and pooled tables are buffered. cluster tables can not buffered.

What is the use of pretty printer ? Exactly where can we link the functional module to abap coding.

Pretty Printer is used to format the ABAP Code we write in ABAP Editor ,like KEY WORDS in Capitals and remaining are in small letters which is also depend on system settings.

We can call the function module in the ABAP Code .Press the Pattern button on Appl. tool bar then u will get box where u write the function module NAME which u want to call in the code by selecting the radio button CALL FUNCTION. In this way we link function module to ABAP Code.

What is the difference between SAP memory and ABAP memory? Answer1: data sending between main sessions using get parameter and set parameter is sap memory data sending between internal sessions using import or export parameters is abap memory

Answer2: sap memory is a global memory whereas abap memory is local memory.

For example, we have four programs in abap memory and assigned some varibles to a particular program in abap memory then those varibles can't be used by anyother program in abap memory i.e., the variables are only for that program and also local to that memory,whereas sap memory can access all the abap memory or else it can perform any kind of modifications.

Answer3: SAP memory is available to the user during the entire terminal session. ABAP memory is available to the user during life time of external session.

at is the difference between Type and Like?Answer1: TYPE, you assign datatype directly to the data object while declaring.

Page 52: Sap Inter Ques1 June2013

LIKE,you assign the datatype of another object to the declaring data object. The datatype is referenced indirectly.

Answer2: Type is a keyword used to refer to a data type whereas Like is a keyword used to copy the existing properties of already existing data object.

Answer3: type refers the existing data type like refers the existing data object

What is Tcode SE16. For what is it used. Explain briefly? Answer1: SE16 is a T-code for object browser. Generally used to search the fields of SAP Tables . and respective data.

Answer2: se16 is a data browse and it is used to view the contents of the table and we cannot change or append new fields to the existing structure of the table as we cannot view the structure level display using the se16

What are different ABAP/4 editors? What are the differences? The 2 editors are se38 and se80 both have the abap editor in place. In se38 you can go create programs and view online reports and basically do all thedevelopmet of objects in this editor. In se80 ( object navigator) there are additional features such as creating packages,module pool , function group ,classes, programs ( where you can create ur programs) and BSP applications .

What is difference between dialog program and a report? Report is a excecutable program Dialog is a module pool program.It has to be executed via a transaction only. Dialog programming is used for customization ofscreens

How do you connect to the remote server if you are working from the office for the client in remote place. WAS web application server or ITS are generally used for this purpose. If you are sitting at your office with a server which is in the system and the other server is at the clients place you can generate IDOC, intermidiate documents which carry the data you want to transfer or the documents you want to transfer, these IDOC are interpretted by the system at the recieving end with the message class with which it is bound with. If you want to logon a system which is very distant..then remote login can be used this depends on the internet speed.

Explain about roll area , Dispatcher, ABAP-Processor. Answer1: Roll area is nothing but memory allocated by work process. It holds the information needed by R/3 about programs execution such as value of the variables. Dispatcher :All the requests that come from presentation server will be directed first to

Page 53: Sap Inter Ques1 June2013

dispatcher. Further dispatcher sends this requests to work process on FIFO(First In and First Out) basis.

Answer2: Dispatcher recieves the request from client and assigns the request to one of the work process. Roll area: Each workprocess works in a particular memory that memory is known as Role Area, which consists of User context and session data. ABAP- Processor :is an interpretor which can execute logic

Which one is not an exit comand ? (Exit, cencle, stop, back) STOP.Effect :The statement STOP is only to be used in executable programs

EXIT.Effect :If the EXIT statement is executed outside of a loop, it will immediately terminate the current processing block.

BACK.Effect : This statement positions the list cursor on the first position of the first line in a logical unit.

So "Cancle" is not an exit command

What is Field symbol ? Answer1: You can use field symbols to make the program more dynamic. In this example the name of a table control is substituted by a field symbol. Thus you cal call the form with any internal table, using the name of the table control as a parameter.

Exampleform insert_rowusing p_tc_name.

field-symbols <tc> type cxtab_control. "Table control

assign (p_tc_name) to <tc>.

* insert 100 lines in table control <tc>-lines = 100.

Answer2: fieldsymbol has the same concept as pointer in c, fieldsymbol don't point to a data type like char, num instead of that it points to the memory block. the syntax for fieldsymbol is FIELD-SYMBOL <N>. EG. FOR FIELD SYMBOL.

Page 54: Sap Inter Ques1 June2013

DATA: DAT LIKE SY-DATUM, TIM LIKE SY-UZEIT, CHAR(3) TYPE C VALUE 'ADF'. FIELD-SYMBOL : <FS>. MOVE DAT TO <FS>. WRITE:/ <FS>. MOVE TIM TO <FS>. WRITE:/ <FS>. MOVE CHAR TO <FS>. WRITE:/ <FS>. The output will be Today's date current time

What is lock object ? LockObjects used to synchornize access of several users using same data.

Why BAPI need then BDC ? BAPI"S provide the standard interface to other applications apart from SAP and within differnt vesions of SAP too. Also it is OOD bases so dosen"t depends on screen flow. BDC gets failed if we make changes for screen changes through IMG customization

What are the advantages and disadvantages of using views in ABAP programming ?advantages: view is used to retrieve the data very fastly from the database tables *memory wastage is reduced *faster than joins to retrieve the data from database tables disadvantages: view is not a container,it will not hold the data *view memory is not permanent memory

How data is stored in cluster table? A cluster table conatins data from mulitple DDIC tables. It stores data as a name value pair ( varkey, vardata)

Have you used performance tuning? What major steps will you use for these? First of all tunning can be done In three ways: disk i/o ,sql tunning , memory tunning, Before tunning u have to get the status of your database using Oracle utility called statpack , tkprof, then you should go for tunning

How to create client independent tables? client independent tables: the table in which the first field is not mandt is the client independent tables *mandt is the field with mandt as the data element *automatically client which we login is populated to mandt

Page 55: Sap Inter Ques1 June2013

What type of user exits have you written? there are four types 1.function exit 2.menu ixit 3.screen exit. 4.field exit. these are the user exits

How can you debug a script form? SE71 -> give the form name -> utilities -> activate debugger

How do we debug sapscript? First we need to put Break point in Print program where ever you want to stop the execution. After in SE71 give your form name and go to Utilities-->Active De-bugger. Then go to your transcation like VF03(for Invoice or Credit memo) etc to see the print preview or print the form execute it. When you execute it the the form Debugging will get activated and you can see your Form execution step by step.

What are the different types of data dictionary objects? Answer1Data Dictionary Objects

* Tables* Views* Domain* Data Element* Type Groups* Search Helps/Matchcode Objects* Lock objects* Structures* Table Types

Answer2the dictionary objects are: domain dataelements tables views structures typegroups search helps lock objects etc which are data base related objects in sap

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

Page 56: Sap Inter Ques1 June2013

steps to create database tables 1.go to se11 2.give name the database table 3.give short description for the table 4.Give delivery class name as A and data browser / table view maint as Display/maintenence allowed 5.select fields tab 6.give field name data type(user defined element type/built-in-type),short text 7.select technical settings tab ,give data class as appl0 and size category as 0 8.save it 9.go utillities menu click table contents select create and enter the field values then select display in table contents and u can view the table values with field lables

Answer2bottom to top approach: _________________________ step 1: creating a domain: *se11,select the object type as domain ,name it ,create,description,enter the datatype and length(size),save ,activate step2: creating a dataelement; se11,select the object type as :date element,name it ,create,desc,assign it with a domain what we created now,save,activate it. step3: creating a table; se11,select the object type as table,name it, create, enter the field name and assign it with the data element instead of assigning a datatype to it, like this create req fields: on behalf of this: table maintainence: assign the type of the table ie.,A C G L S NEXT maintaince: allowed,not allowed ,allowed with restricions ______________________________________________ fields of a table:(as descripted above) ___________________________________________ techical settings: A0 OR A1 AND BUFFERED OR NON-BUFFERED

Page 57: Sap Inter Ques1 June2013

Can a transparent table exist in data dictionary but not in the data base physically? Answer1NO. TRANSPARENT TABLE DO EXIST WITH THE SAME STRUCTURE BOTH IN THE DICTIONARY AS WELL AS IN THE DATABASE,EXACTLY WITH THE SAME DATA AND FIELDS. No,at the point you will activate your table a same transparent table is going to be create in database

Answer2Yes, a transparent table(definition) can exist in the data dictionary and not in the database. In this case, it is not activated

What are the domains and data elements?

domains:___________

domains are the dictionary objects that are assigned with constants and data types data elements: ______________ data elements are dictionary objects that are assigned with the domains. uses:' * data elements are used to create relation between tables. * data elements are used to transfer the data from one R/3 to another R/3. * to create search helps.

What is a collect statement? How is it different from append? APPEND :IT IS USED TO GET THE RECORD FROM THE INTERNAL TABLE HEADER TO THE BODY AREA IT ALLOWS DUPLICATION

COLLECT:IT IS USED TO A GET A RECORD FROM HEADER TO THE BODY AREA BUT IT WILL NOT ALLOW ANY DUPLICATION EXCEPT IF THERE IS ANY NUMERIC FIELS IT ADDS THAT FIELDS DATA BUT NOT AS A NEW RECORD

On ABAP: Did you set up a workflow? Are you familiar with all steps for setting up a workflow? Yes. Execute the Txn SWDD(Creating a new Workflow). In the header of the Workflow, define the Business Object and Event you refer to for triggering the Wf. Create the Steps required for your workflow(Activity). Inside the Activity, Create the task and assign the Business Object and the related method for

Page 58: Sap Inter Ques1 June2013

that business object. Activate the Workflow.

In the ‘select’ statement what is “group by”? Group by clause is used to fetch the data from the table by the specified field ex.select count (*) from emptable group by deptno where deptno = 1. It is used to find the number of employees present in the specified department no.

How can I copy a standard table to make my own z_table? WE CAN CREATE A STRUCTURE LIKE THE SAME STRUCTURE AS DATABASE TABLE AND WE CAN USE SELECT* FROM DATABASE TABLE INTO TABLE ITAB OR INSERT INTO ITAB VALUES DATABASE TABLE

From Excel to ABAP - Is batch mode possible ? DATA w_file TYPE string.* Convert the file path into stringw_file = p_input.

* Internal Table should have same field sequence as EXL File.

CLEAR t_upload.REFRESH t_upload.

* Call function to upload the data into internal tableCALL FUNCTION 'GUI_UPLOAD'EXPORTINGfilename = w_filefiletype = 'ASC'has_field_separator = 'X'TABLESdata_tab = t_uploadEXCEPTIONSfile_open_error = 1file_read_error = 2no_batch = 3gui_refuse_filetransfer = 4invalid_type = 5no_authority = 6unknown_error = 7bad_data_format = 8header_not_allowed = 9separator_not_allowed = 10header_too_long = 11unknown_dp_error = 12

Page 59: Sap Inter Ques1 June2013

access_denied = 13dp_out_of_memory = 14disk_full = 15dp_timeout = 16OTHERS = 17.IF sy-subrc NE 0.* MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno* WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4. ELSE.* Delete the first row of heading from the uploaded tableDELETE t_upload INDEX 1.ENDIF. " IF sy-subrc EQ 0.

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

· The external layer.

· The ABAP/4 layer.

· The database layer.

Define 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.

Define ABAP/4 layer?

The ABAP/4 layer describes the data formats used by the ABAP/4 processor.

Define Database layer?

The database layer describes the data formats used in the database.

What is a Data Class?

The Data class determines in which table space the table is stored when it is created in the database.

Page 60: Sap Inter Ques1 June2013

What is a Size Category?

The Size category describes the probable space requirement of the table in the database.

How many types of size categories and data classes are there?

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 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.

What are control tables?

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

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.

What is a table pool?

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).

Page 61: Sap Inter Ques1 June2013

What are pooled tables?

These 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 or program parameters).

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.

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.

Which objects are independent transport objects?

Domains, Data elements, Tables, Technical settings for tables, Secondary indexes for transparent tables, Structures, Views, Matchcode objects, Matchcode Ids, Lock objects.

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.

Page 62: Sap Inter Ques1 June2013

What are the Data types of the external layer?

ACCP, Char, CLNT, CUKY, CURR, DATS, DESC, 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:

C: Character.

D: Date, format YYYYMMDD.

F: Floating-point number in DOUBLE PRECISION (8 bytes).

I: Integer.

N: Numerical character string of arbitrary length.

P: Amount of counter field (packed; implementation depends on h/w platform).

S: Time Stamp YYYYMMDDHHMMSS.

V: Character string of variable length, length is given in the first two bytes.

X: Hexadecimal (binary) storage.

How can we set the table spaces and extent sizes?

You can specify the extent sizes and the table space (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 the function of the correction system?

The correction system manages changes to internal system components. Such as objects of the ABAP/4 Dictionary.

What are local objects?

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

Page 63: Sap Inter Ques1 June2013

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.

What is a data dictionary?

Data Dictionary is a central source of data in a data management system. Its main function is to support the creation and management of data definitions. 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.

· Provision of information for evaluation.

· Support for s/w 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 aABAP/4 Development Workbench.

· Active in the runtime environment.

Page 64: Sap Inter Ques1 June2013

What are the uses of the information in the Data dictionary?

The following information is directly taken from the Data dictionary:

· Information on fields displayed with F1 help.

· Possible entries for fields displayed with F4 help.

· Matchcode and help views search utilities.

What are the basic objects of the data dictionary?

· Tables

· Domains

· Data elements

· Structures

· Foreign Keys

What are the aggregate objects in the data dictionary?

· Views

· Match codes

· Lock objects.

In the ABAP/4 Dictionary Tables can be defined independent of the underlying database (T/F).

True.

ABAP/4 Dictionary contains the Logical definition of the table.

A field containing currency amounts (data type CURR) must be assigned to a reference table and a reference field. Explain.

As a reference table, a system containing all the valid currencies is assigned or any other

Page 65: Sap Inter Ques1 June2013

table, which contains a field with the currency key format. This field is called as reference field. The assignment of the field containing currency amounts to the reference field is made at runtime. The value in the reference field determines the currency of the amount.

A field containing 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 quantity units is assigned or any other table, which contains a field with the format or quantity units (data type UNIT). This field is called as reference field.

The assignment of the field containing quantity amounts to the reference field is made at runtime. The value in the reference field determines the quantity unit of the amount.

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 allows us to

· Optimize storage space requirements.

· Table access behavior.

· Buffering required.

· Changes to entries logged.

What is a Table attribute?

The table’s 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 maintenance allowed.

· Activation type.

What is the significance of Delivery Class?

· The delivery class controls the degree to which the SAP or the customer is responsible for

Page 66: Sap Inter Ques1 June2013

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 is the max. no. Of structures that can be included in a table or structure.

Nine.

What are two methods of modifying SAP standard tables?

· Append Structures and

· Customizing Includes.

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

· 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.

To how many tables can an append structure be assigned.

One.

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

Long fields in a table must always be located in the end, as the last field of the table. If a table has an append structure the append line must also be on the last field of the table.

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

No.

Page 67: Sap Inter Ques1 June2013

What are the two ways for restricting the value range for a domain?

· By specifying fixed values.

· By stipulating a value table.

Structures can contain data only during the runtime of a program (T/F)

True.

What are the aggregate objects in the Dictionary?

· Views

· Match Code.

· Lock Object.

What are base tables of an aggregate object?

The tables making up an aggregate object (primary and secondary) are called aggregate object.

The data of a view is not physically stored, but derived from one or more tables (t/f)

True.

What are the 2 other types of Views, which are not allowed in Release 3.0?

· Structure Views.

· Entity Views.

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.

Page 68: Sap Inter Ques1 June2013

What are the two levels in defining a Match Code?

· Match Code Object.

· Match Code Id.

What is the max no of match code Id’s that can be defined for one Match code object?

A match code Id is a one character ID that can be a letter or a number.

Can we define our own Match Code ID’s for SAP Matchcodes?

Yes, the number 0 to 9 are reserved for us to create our own Match Code Ids for a SAP defined Matchcode object.

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

If the data in one of the base tables of a matchcode ID changes, the matchcode data has to be updated. The update type stipulates when the matchcode is to be updated and how it is to be done. The update type also specifies which method is to be used for Building matchcodes. You must specify the update type when you define a matchcode ID.

Can matchcode object contain Ids with different update types?

Yes.

What are the update types possible?

The following update types are possible:

· Update type A: The matchcode data is updated asynchronously to database changes.

· Update type S: The matchcode data is updated synchronously to database changes.

· Update type P: The matchcode data is updated by the application program.

Page 69: Sap Inter Ques1 June2013

· Update type I: Access to the matchcode data is managed using a database view.

· Update type L: Access to the matchcode is achieved by calling a function module.

What are the two different ways of building a match code object?

A match code can be built in two different ways:

· Logical structure: The matchcode data is set up temporarily at the moment when the match code is accessed. (Update type I, k).

· Physical Structure: The match code data is physically stored in a separate table in the database. (Update type A, S, P).

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 transparent tables and pooled and cluster tables.

What is the function of a Domain?

· A domain describes the technical settings of a table field.

· A domain defines a value range, which sets the permissible data values for the fields, which refers to this domain.

· A single domain can be used as basis for any number of fields that are identical in structure.

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

No.

What are conversion routines?

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

Page 70: Sap Inter Ques1 June2013

What is the function of a data element?

A data element describes the role played by a domain in a technical context. A data element contains semantic information.

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

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

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

No.

Can you define a field without a data element?

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.

What are null values?

If the value of a field in a table is undefined or unknown, it is called a null value.

What is the difference between a structure and a table?

Structures are constructed the almost the same way as tables, the only difference using that no database table is generated from them.

What is a view?

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.

Page 71: Sap Inter Ques1 June2013

How many types of Views are there?

· Database View

· Help View

· Projection View

· Maintenance View

What is Locking?

When two users simultaneously attempt to access the same data record, this is synchronized by a lock mechanism.

What is database utility?

Database utility is the interface between the ABAP/4 Dictionary and the underlying the SAP system.

What are the basic functions of Database utility?

The basic functions of database utility are:

· Create database objects.

· Delete database objects.

· Adjust database objects to changed ABAP/4 dictionary definition.