Вы находитесь на странице: 1из 49

ABAP Interview Questions

Table of contents
1. Basics................................................................................................................................... 2 2. Internal Tables...................................................................................................................... 2 3. Data Dictionary..................................................................................................................... 4 4. Reports................................................................................................................................. 6 5. Modularization using Subroutines......................................................................................... 9 6. Memory Management......................................................................................................... 11 7. Lock Objects....................................................................................................................... 12 8. Logical Database................................................................................................................ 14 9. Number Ranges.................................................................................................................. 15 10. LUW.................................................................................................................................. 15 11. Database Update.............................................................................................................. 16 12. ABAP OBJECTS............................................................................................................... 16 13. Module Programming........................................................................................................ 23 14. Enhancements.................................................................................................................. 27 15. Performance Optimization.................................................................................................32 16. Smartforms....................................................................................................................... 35 17. SapScripts......................................................................................................................... 37 18. BDC.................................................................................................................................. 39 19. ALE/IDOC......................................................................................................................... 42

1. Basics
Easy questions Q. A. Q. A. Architecture - 3 different layer Presentation, Application, Database Different type of work processes Update, Spool, Background, Dialog, Enqueue/Dequeue

Medium Questions Q. A. Q. A. Q. A. Two services that are used to deal with communication Message Server and Gateway Server How many enqueue work process possible 1 What is the function of dispatchers It distributes the load to the available work process.

Difficult Questions Q. A. What is the use of message server and gateway server Message server is use to communicate between different dispatchers while Gateway server is use to communicate between the systems.

2. Internal Tables
Easy questions

Q. A.

What are different types of internal table Standard, Sorted, and Hashed table. - Standard table is used mainly for fetching records using index with basically non-unique keys. - Sorted table is used for both unique/non unique keys. Index access also possible. - Hash table no index allow. Fetching only using full primary keys What are the data types that makes the default key of internal table C,N,D,T,S Which is the system field to check whether record was found or not sy-subrc How to remove duplicate records from an internal table Delete adjacent duplicates from internal table

Q. A. Q. A. Q. A.

Medium Questions Q. A. What are different method for defining internal tables and what is the difference when used with clear statement We can define it with header line/ without header lines. With header lines: Clear statement only clears the header line. Without header line: Clear statement clear the body content How to find total number of records in an internal table Describe table itab lines i What is the difference between select single and select up to 1 rows In select single, full primary key should be specify. While in select upto 1 row it is not necessary. It will fetch the first found record. What are the different ways of reading internal tables? What is the difference them 1. Read table itab into wa_area 2. Read table itab assigning wa_area. In case 1, it copies the records into wa_area while in 2nd case it sets a pointer. Any changes made to the wa_area, it will automatically get reflected in the internal table. 3. Read table itab index n 4. Loop at internal table into wa_area. What is the use of transporting fields while reading internal table By using transporting f1,f2 or transporting all fields, we can copy only the required fields in the work_area How does comparing statement works in read statement It will first compare whether the required fields is present in the internal table. If yes, then only it will transfer the required fields into work_area. What are the basic requirements when we use for all entries 1. Check for initialization. 2. Sort and remove duplicate records by using delete adjacent duplicate

Q. A. Q. A. Q. A.

Q. A. Q. A. Q. A.

Q. A. Q. A.

What is the other way instead of reading, changing the value and then modify Use assigning field-symbols instead of work area What are the control break statements At first---- It will execute only once i.e. at the first loop pass At last-----It will execute only once i.e. at the last loop pass At new of--It will execute at every new value of control level At end of--It will execute at the end of new control level At sum --It will do the sum of all other numeric field for the that control level field value What is the basic criteria to use control break statement Sort the table in ascending order In which field will the index of read records of an internal table be stored sy-tabix

Q. A. Q. A.

3. Data Dictionary
Easy questions Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. What is the use of domain It is use to describe the technical attributes of a field (data type and length) What are the two ways for restricting the value range for a domain By specifying fixed values, By stipulating a value table What is the use of data element It is used for describing short text of a field, It can also be used as a label for field on the selection screen 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 is data class used for It is used to specify on which physical area of database the table should be stored. What is size category used for It specifies the amount of space (extent) allocated. Different types of views Database, Projection, Maintenance, Help views Different types of search help Elementary Search help, Collective Search help

Medium Questions

Q. A. Q. A. Q. A.

What are the two methods of modifying SAP standard tables Append Structures, Customizing Includes What are the technical settings maintained while creating the table Data Class, Size Category, Logging , Buffering Different type of buffering? Explain Full Buffering - When a record is read from the table, entire records of that table is loaded into the buffer. When the table is small, and more frequently it is read and less it is written, full buffering is used. Generic Buffering- When a record is read from the table, it generics part of the key which are same are loaded into the buffer. Single buffering - When a record is read from a table, only that record is loaded into the buffer. It is used for large table. If suppose a particular record is not present in the database table, it will be marked as non-existence and that record will be uploaded in the buffer. Now if u tries to read the same record, it will be read from the buffer.

Q. A.

2 level domain Concept Two different data element use the same domain. It is used when technical attributes of both data element are same. So that if domain changes, it will be reflected in both the data element What is the difference between database view and maintenance view If database view consists of more than one table, then only read status is possible with this view. It is not possible to insert record through this view. While maintenance view allows to maintain (insert) the records in table. What is use of value table in domain If table is specified as value table while maintaining domain, it will be proposed as check table when defining foreign key on the field which uses this domain. What is the difference between active and generated version. Active version is that version which is accessible by all users. Suppose if program is active, then all user will use that active program. Now suppose the program is changed, but it is in the inactive state. Now if other users try to access this program, they will be accessing only the active version and not the changes. Whereas if the user who has changed the program, and if it execute, it will be executing the new generated version. What is type groups Type Groups are used to store user-defined data types or constants in ABAP 4 Dictionary for cross-program use. In ABAP/4 programs, you define type groups with the TYPE-POOLS statement. 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 table containing all the valid currencies is assigned or any other table which contains a field with the currency key format (CUKY). This field is called as reference field.

Q. A.

Q. A. Q. A.

Q. A.

Q. A.

Q. A.

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 for quantity units (data type UNIT). This field is called as reference field. 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.

Q. A.

4. Reports
Easy questions Q. A. Q. A. Q. A. Which is the first event triggered in a report Start-of-selection (if event initialization is not present) When top-of-the-page event is triggered At the start of new page What are the events in ABAP program Initialization / Load-of-program Start-of-selection. At Selection Screen Output At Selection Screen Top-of-page At line-Selection AT USER-COMMAND Top-of-page during line-selection End-of-page End-of-selection. What are the control level events AT First At New At End of At Last What indicates success or failure of a SQL operation SY-SUBRC Name the ABAP/4 key words which are used to change the contents of database table UPDATE or MODIFY In the statement Write: / 15 (10) lfa1-lifnr. , what do the numbers 15 and 10 stand for

Q. A.

Q. A. Q. A. Q.

A.

15 stands for the offset on the screen and 10 stands for the field length displayed.

Medium Questions Q. A. What are the event key words in interactive reporting AT LINE-SELECTION Moment at which the user selects a line by double-clicking on it or by positioning the cursor on it and pressing F2. AT USER-COMMAND Moment at which the user presses a function key. TOP-OF-PAGE DURING LINE-SELECTION Moment during list processing of a secondary list at which a new page starts. What is the use of LINE-COUNT <lines_per_page> The use of LINE-COUNT <lines_per_page> (<footer_lines>) indicates that the page has a fixed number of lines part of which is reserved for use at the END-OF-PAGE event. How to suppress the standard page heading in report NO STANDARD PAGE HEADING addition How can you maintain header Goto Text Elements List Heading or System List List Header. How to colors the line background FORMAT COLOR ON How to suppresses output of spaces after the <f> field NO-GAP What does <LIST> include contains The <LIST> include contains include statements for <SYMBOL>, <ICON>, <LINES>, and <COLOR>. What are system fields for secondary lists SY-LSIND Index of the list created during the current event (basic list = 0) SY-LISTI Index of the list level from which the event was triggered SY-LILLI Absolute number of the line from which the event was triggered SY-LISEL Contents of the line from which the event was triggered

Q. A.

Q. A. Q. A.

Q. A. Q. A. Q. A. Q. A.

SY-CUROW Position of the line in the window from which the event was triggered (counting starts with 1) SY-CUCOL Position of the column in the window from which the event was triggered (counting starts with 2) SY-CPAGE Page number of the first displayed page of the list from which the event was triggered SY-STARO Number of the first line of the first page displayed of the list from which the event was triggered (counting starts with 1). Possibly, a page header occupies this line. SY-STACO Number of the first column displayed in the list from which the event was triggered (counting starts with 1) SY-UCOMM Function code that triggered the event SY-PFKEY Status of the displayed list Q. A. Q. A. Q. A. To execute a page break under the condition that less than a certain number of lines are left on a page is achieved by RESERVE n lines What are the events used for page headers and footers The events TOP-OF-PAGE and END-OF-PAGE are used for page headers and footers What is the difference between PARAMETERS and SELECT-OPTIONS The system generates input-ready fields in the selection screen with PARAMETERS stmt. Whereas SELECT-OPTIONS allows a range of values as well as complex selections instead of just a single input-ready field. If you make reference to a dictionary object that has a foreign key established, how to verify that the input is valid. Using VALUE CHECK How to suppresses multiple single or multiple range selections in select-options NO-EXTENSION How to suppresses the seltab-high (upper interval limit) entry on the selection screen NO INTERVALS When is AT SELECTION-SCREEN ON END OF <field> The event AT SELECTION-SCREEN ON END OF <field> belongs to the PAI processing of the selection screen for multiple selections

Q. A. Q. A. Q. A. Q. A.

Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A.

How to provide F1 (general help) and F4 (possible entries) in report program AT SELECTION-SCREEN ON HELP-REQUEST and AT SELECTION-SCREEN ON VALUE-REQUEST. What is the difference between LOAD-OF-PROGRAM and INITIALIZATION Initialization is available for executable programs only. If both events are present in program, LOAD-OF-PROGRAM will be executed first. How many parallel detail lists possible in interactive reports? What happen if it exceed 20 parallel lists are possible. If it exceeds 20, it gives a short dump. How does data transport takes place between list 1)Using Hide area 2)GET CURSOR statement to create detail lists according to the cursor position Is the basic list deleted when the new list is created NO. It is not deleted In which system field does the name of current gui status is there The name of the current GUI STATUS is available in the system field SY-PFKEY What is meant by hide area The hide command temporarily stores the contents of the field at the current line in a system-controlled memory called the HIDE AREA. At an interactive event, the contents of the field is restored from the HIDE AREA What is GET CURSOR command used for The GET CURSOR command returns the name of the field at the cursor position in a field specified after the addition field, and the value of the selected field in a field specified after value. How to call other programs Report Call and return - SUBMIT AND RETURN Call without return SUBMIT Transaction Call and return - CALL TRANSACTION Call without return - LEAVE TO TRANSACTION

Q. A.

Q. A.

5. Modularization using Subroutines Easy questions Q. A. What is a subroutine and why is it required A subroutine is an internal module within a program. Using subroutines makes your program more function oriented: it splits the program's task into sub functions so that each subroutine is responsible for one sub function. This generally makes programs

easier to maintain. Q. A. How do you define the structure of a subroutine The structure of a subroutine includes the following: - Each subroutine starts with FORM and ends with ENDFORM. - The name of the subroutine is followed by the interface definition. - The statements that the subroutine executes come between FORM and ENDFORM. What are actual and formal parameters with respect to a subroutine Data which is passed from the main program is called actual parameters. Data received in the interface of the subroutine is called formal parameters. How are internal tables passed By reference

Q. A. Q. A.

Medium Questions Q. A. Methods of parameter passing between main program and subroutine Call-by-value A local copy of the actual parameter is passed to the subroutine. This means that value assignments to the formal parameter have absolutely no effect on the actual parameter. Call-by-reference A dereference address of the actual parameter is passed to the subroutine. This means that value assignments to the formal parameter directly affect the actual parameter. The value of the actual parameter is physically changed by the subroutine through the address. Call-by-value-and-result A local copy of the actual parameter is passed to the subroutine and a value is passed back to the main program only if the ENDFORM statement is executed. This means that value assignments to the formal parameter affect the actual parameter only after they have left the subroutine. Choose this option if you want to make sure that the actual parameter is not changed if the subroutine is terminated prematurely. Q. A. What is the sequence of parameter passing The sequence of parameters is fixed: first you name all the USING parameters, and then you name all the CHANGING parameters. The actual parameters are grouped by USING and CHANGING when the subroutine is called. Way in which parameters are passed to the interface Call-by-value (f1) You list these parameters after the USING keyword and complete them with the value (f1) addition. Call-by-reference (f2) You list these parameters after the CHANGING keyword. (For documentation purposes, you can also list a pass-by-reference parameter after USING. Technically, USING and CHANGING have exactly the same effect. (However, if you change a parameter listed after USING in the subroutine, you receive a warning in the Extended Program Check.) Call-by-value-and-result (f3) You list these parameters after the CHANGING keyword and complete them with the value(f3) addition

Q. A.

10

Q. A.

Do we need to specify the type of the formal parameters If you use elementary types, you can decide whether or not you want to specify the type of the formal parameters. By specifying the type of the formal parameters, you ensure that only actual parameters of that type can be passed to the subroutine. What happens if you leave the type unspecified and how do you do that If you use the TYPE ANY addition, you leave the type unspecified. (For compatibility reasons, you can also omit this addition.) In this case, the formal parameter inherits the type from the actual parameter at run time. If the statements in the subroutine are not suited to the inherited type, a runtime error may occur. What is the life of local variables and formal parameters Both the formal parameters and the local data objects are active only at the run time of the subroutine. This means that memory is allocated only when the subroutine is called and is released as soon as the subroutine has been executed. Thus these parameters and data objects can be addressed only from within the subroutine. Can we keep the name of a local data object or a formal parameter same as that of a global variable OR What are locally obscured objects If a local data object or formal parameter has the same name as a global data object, the ABAP runtime system addresses the local data object in the subroutine and the global one outside it. These objects are then known as locally obscured objects. What about passing structures and internal tables If you use structures or internal tables as formal parameters, you must type them fully. This allows you to access these formal parameters within the subroutine. If you use internal tables, the assigned type allows you to address the formal parameter as an internal table with the usual syntax.

Q. A.

Q. A.

Q. A.

Q. A.

6. Memory Management
Medium Questions Q. A. What happen when we call function module from a program When a function module is called, the corresponding function group is loaded into the current internal session and the called function module is processed. Processing of the calling program is interrupted and continued after the function module has been executed. What happen when we call program using CALL TRANSACTION or SUBMIT AND RETURN The program called using CALL TRANSACTION or SUBMIT AND RETURN runs in a separately opened internal session that contains a new program context. After the called program has been completed, the new internal session is deleted and processing is continued for the calling program. What happen if a program is called through the SUBMIT statement.

Q. A.

Q.

11

A.

If a program is called through the SUBMIT statement, the context of the calling program is removed from the current internal session and the called program is loaded for processing. What happen when LEAVE TO TRANSACTION statement is used The LEAVE TO TRANSACTION statement removes all the internal sessions of the current external session and opens a new internal session for processing the called transaction. When this happens, the ABAP memory is initialized! This means, in particular, that you cannot pass any data to the called transaction through the ABAP memory. What happen when asynchronous function module is called Function modules that have been called asynchronously are processed on the same application server in a newly opened external session What are the different ways of passing on data to a program when it is called

Q. A.

Q. A. Q. A.

Through the interface of the called program (interface of a subroutine, function


module, or dialog modules, standard selection screen of a report) Through the ABAP memory Through the SAP memory Through database tables Through files on your presentation server or application server

Q. A.

What do you mean by EXPORT TO MEMORY ID <id> statement Using the EXPORT TO MEMORY ID <id> statement, you can copy variables of your program with their current values as data clusters into the ABAP memory. The ID you specify here uniquely identifies the created data cluster (maximum 32 characters). An export to the same memory ID will overwrite the corresponding data cluster How to delete the respective data cluster. FREE MEMORY ID <id> What is the difference between ABAP Memory and SAP Memory ABAP Memory is used to pass data between internal sessions of external session. It is done using EXPORT and IMPORT statement. Whereas SAP memory is used to pass data between external sessions of a user terminal. It is done using SET PARAMETER and GET PARAMETER.

Q. A. Q. A.

7. Lock Objects
Easy questions Q. A. Q. A. Which are the 2 function modules generated while creating lock objects Enqueue_<lock object name>, Dequeue_<lock object name> What are there uses? Enqueue_<lock object name> - To set lock on records of a table or entire table itself, Dequeue_<lock object name> - To release lock

12

Q. A. Q. A.

Which is the function module to release all lock Dequeue_all What is the order to be followed while updating database table? Lock - Read - Change Unlock

Medium Questions Q. A. What are the 3 modes while creating lock objects Shared(S), Exclusive(X) and Extensible(E) Shared - This mode ensures that data displayed in your program cannot be changed by other users during the entire display time. Exclusive - This mode is used like mode E for changing data. The only technical difference from mode E is that the respective lock does not allow accumulation. Extensible - This sets a lock for changing data. This lock can be accumulated. Difficult Questions Q. A. What is the use of container in lock object For every lock request, it contacts administrator. So if there are more locks to be set, it has to communicate again and again. In order to communicate only once, container concept came into picture. While setting the lock, set the collect_container parameters as 'X' to keep it in container. Then use function module ENQUEUE_FLUSH to set lock for all object. If any error, then neither of the lock is set. What is the effect of setting another lock from other program (PGM2), when already lock is provided on the same table in some program (PGM1)? PGM 2 PGM 1(Mode already set) Only shared(S) possible Not possible Not possible Q. A. S X E

Q. A.

What is the effect of setting another lock from same program (PGM1), when already lock is provided on the same table in program (PGM1)? PGM 1 PGM 1(Mode already set) Shared(S) and E possible S (If you have an existing S lock, further S locks for the same data record can be set from within the same program. If, in addition, there are no further shared locks set by another user for this data record, you can also set an additional E lock. No X lock can be set if there is an existing S lock.) Not possible Shared(S) and E possible X E

13

8. Logical Database
Easy questions Q. A. Q. A. Q. A. Q. A. How do we specify a logical database in program? You must enter the LDB name in the program's attributes. Three main elements of LDB. Structure, Selections, Database Program. In LDB what determines hierarchy of the tables? Structure. The layout of the Database program is determined by both Structure and selections.

Medium Questions Q. A. What are the advantages of Logical Data Bases? -The system generates a selection screen. -The programmer does not need to know the exact structure or relationship of the tables involved; the data is made available to the application program in primary key sequence. Data is formatted for output in the GET events. -Performance improvements within logical databases directly affect all programs linked to the logical database without having to change the programs themselves. -Maintenance and enhancements can be performed at a central location. -Authorization checks are done in the logical database program rather than in the application program. When is Get <node> Late event triggered? The GET <node> LATE event triggers when all subordinate nodes of node <node> have been processed, before the data is read for the next <node> (whenever a hierarchy level has been completed). How the interaction between LDB and database does takes place? When a report program that uses a logical database is started, control is initially passed to the database program of the logical database. Each event has a corresponding subroutine in the database program (for example, subroutine init for event INITIALIZATION). During the interaction between the LDB and the associated report, the subroutine is always processed first, followed by the event (if there is one in the report). Logical database programs read data from a database according to the structure declared for the logical database. The logical database reads the data in the PUT_<NODE> subroutines. During event PUT, control passes from the database program to the GET event of the associated report. The data is made available in the corresponding work areas in the report. The processing block defined for the GET event is performed. Control then returns to the logical database. PUT activates the next form subroutine found in the structure.

Q. A.

Q. A.

14

Difficult Questions Q. Suppose a logical database program contains the following lines : SELECT-OPTIONS CONNID FOR SPFLI-CONNID . PARAMETERS CARRID LIKE SFLIGHT-CARRID FOR TABLE SFLIGHT. If the tables statement in a report declares only SPFLI but not SFLIGHT what will be the output, for the above two statements? Only select-options connid for spfli-carrid will be displayed on the screen. Consider a report with F1S attribute, what will be the output for the following code. Whether you will get the data from spfli and sflight or not, with corresponding tables statement GET SBOOK. Write: / spfli-carrid, spfli-connid, sflight-fldate, sbook-bookid. (F1S structure SPFLI-->SFLIGHT-->SBOOK) Yes, you will get the data from spfli and sflight. Consider a report with F1S attribute, what will be the output for the following code. Whether you will get the data from spfli and sflight or not, with corresponding tables statement GET SFLIGHT. Write: / spfli-carrid, spfli-connid, sflight-fldate, sbook-bookid. You cannot extract data from sbook.

A. Q.

A. Q.

A.

9. Number Ranges
Easy questions Q. A. Q. A. Q. A. Number range object maintenance Transaction SNRO What does Warning % field indicate while defining number range object This determines with which percentage of remaining interval a warning is displayed Which is the function module used in determining the next available number NUMBER_GET_NEXT

Medium Questions Q. A. Can we define different number range intervals for one object Yes, either specify the fiscal year or specify numbers in number range field

10. LUW
Medium Questions Q. A. Different type of LUW SAP LUW , Database LUW An SAP LUW (Logical Unit of Work) consists of changes in SAP R/3 that logically belongs together. These changes are either carried out in full or they are not carried out at all ("all or nothing" principle). A database LUW consists of changes that are executed until the database status is "sealed" (DB Commit). Within a database LUW, it is always possible to discard all the

15

changes that have taken place up to that point (DB rollback), in which case the database is reset to the status it had before the current database LUW. You use this DB rollback function to restore the previous (consistent) database status if an error has occurred. The SAP LUW must be processed within a DB LUW.

11. Database Update


Easy questions Q. A. Q. A. Q. A. How do u create update function module Using transaction SE37, then selecting processing mode as Update Module Update function module includes which interface parameters IMPORTING and TABLES parameters Which system field will contain how many records in database has been process sy-dbcnt

Difficult Questions Q. A. If you want your database updates from dialog mode to be executed in bundled form , i.e. you want to ensure that your database changes are processed using the "all or nothing" principle, what should be done. By using the special subroutine technique PERFORM <subroutine> ON COMMIT. The statement PERFORM <subroutine> ON COMMIT registers the subroutine that has been specified. This will not be executed until the system reaches the next COMMIT WORK statement Two types of update modules V1 and V2 When programming inline changes and update modules, what are the rules to be adhere? Create new table entries first. Their database locks pose the least "interference" for other users. Perform table updates that are not critical to performance. As a rule, these tables are accessed simultaneously by relatively few users. Always change tables that represent central resources in the system (tables accessed by several users simultaneously) late within an LUW, if possible, so that the respective database locks hinder others only for a short time.

Q. A. Q. A.

12. ABAP OBJECTS


Easy questions Q. Why did ABAP Objects come into picture when we have function group ( as class in ABAP Objects is equivalent to function group )

16

A.

1) When we call function module of Function group, its entire instance is loaded into internal session of program memory. When we call function module again, it uses the same instance and work with the changed global attributes. Thus state of an attribute is not maintained through function module. No multiple instances are created. In case of ABAP objects, state of an object is maintained. Multiple instance of a class can also be created. 2)When user uses the function module, it should provide the same interface parameter required by FM. Suppose if FM changes its interface, it will affect many user and its difficult to predict the implication. The only way to avoid this to rely on interfaces that guarantee that it will not be changed or its implementation is hidden from outside world. In FM there is no visibility concept. This requirement is met by ABAP objects through encapsulation.

Q. A. Q. A.

What is equivalent to function group in ABAP Objects Class What is difference between class and objects Class is the template of an object. It is an abstract concept, which is realized by creating an object from it. Example - What is your idea about a Maruti-800 car? You will say that it is a four-wheel, five seater vehicle with an 800 cc engine. The idea you have in your mind is the class for Maruti-800.Let us call it as class Maruti800. Now, you see a real Maruti-800 car in front of you. So, this is the object of class Maruti800. In other words, the real car is realization/ instantiation of the class Maruti-800.

Q. A.

How is object characterized Object is characterized by state of objects, behaviour of an object and identity. State of an object contains the current value of all it attributes. Behaviour of an object is how object acts or reacts to its change of state Identity is that property of objects which makes it unique from other objects.

Q. A.

What is the difference between local classes and global classes Local classes are only known within the program in which they are defined and implemented. Local classes are not stored in the Repository (no TADIR entry). There is no "global" access to these classes or interfaces. No where-used list possible. Global classes are access from all programs using type ref to. Global classes are stored in the Repository (TADIR entry).Where-used list possible

Q. A. Q. A. Q.

What do you mean by READ-ONLY addition to public attribute The READ-ONLY addition means that a public attribute declared with DATA can be read from outside, but can only be changed by methods of the class. How to protect your attributes from access from outside the class Declare it as private attributes. What is the difference between public attribute and private attributes

17

A.

Public attributes can be viewed and changed by all other users. Direct access possible. Private attributes can be viewed and changed by class itself. No access from outside the class. What is the use of private component Let us assume that a class changes its private components, while its interface remains unchanged. Any user who simply needs to access the interface of the class can carry on working with the class as usual. The user does not notice the change. However, if a class changes its public components, then any user who accesses these public components must take these changes into account. How to access private attributes from outside We can access private attributes through public methods. What are two kinds of attributes? What is the difference between them Static attributes exist only once for each class and are visible for all (runtime) instances in that class. Static attributes are defined using the ABAP keyword CLASS-DATA. Instance attributes are attributes that exist separately for each object. Instance attributes are defined using the ABAP keyword DATA.

Q. A.

Q. A. Q. A.

Q. A. Q. A.

What is the difference between Public method and Private method Public method can be called from anywhere. Private method can be called only within the class. What is the difference between instance method and static method Instance method can use both instance and static component. It is called using instance. They are defined using METHODS. Static method can use only static components. It is called using class .They are defined using CLASS-METHODS.

Q. A. Q. A. Q. A.

What do you mean by DATA: r_vehicle1 TYPE REF TO lcl_vehicle DATA: r_vehicle1 TYPE REF TO lcl_vehicle declares a reference variable that acts as a pointer to an object. How to create objects Objects are created using CREATE OBJECT. Objects can only be created and address using reference variables. How to access the instance methods and static methods Instance methods: CALL METHOD <reference>-<method>. Static methods: CALL METHOD <classname>=><class_method>.

Medium Questions Q. A. How do instances of class share their common attributes By declaring components as static.

18

Q. A. Q. A.

What are the interface parameters of methods Methods can have IMPORTING, EXPORTING, CHANGING, RETURNING and RAISING What is functional method Methods that have a RETURNING parameter are described as functional methods. These methods cannot have EXPORTING or CHANGING parameters .You can only do this for a single parameter, which additionally must be passed as a value. What is the use of garbage collector? How do we use it The Garbage Collector is a system routine that automatically deletes objects that can no longer be addressed from the main memory and releases the memory space they occupied. If you want to keep several objects from the same class in your program, how to do Define an internal table which only consists of one column containing the object references for this class. You can process the objects using a LOOP through the internal table. Why only static components can be used in Static methods Whenever static method is invoked, no (ME) address is passed to this methods. What is the use of defining constructor We need to implement the constructor when: We need to initialize attributes that cannot be covered by the VALUE addition to the DATA statement - We need to modify static attributes Can constructor be called explicitly No When is constructor called The constructor is automatically called at runtime within the CREATE OBJECT statement. What is static constructor The static constructor is a special static method in a class with the name class_constructor. It is executed precisely once per program. When is static constructor called The static constructor of a class <classname> is called automatically when the class is first accessed, but before any of the following actions are executed: Creating an instance in the class using CREATE OBJECT <obj>, where <obj> has the data type REF TO <classname> Addressing a static attribute using <classname>=><attribute> Calling a static attribute using CALL METHOD <classname>=><classmethod> Registering a static event handler method using SET HANDLER <classname>=><handler_method> FOR <obj> - Registering an event handler method for a static event in class <classname>.

Q. A.

Q. A.

Q. A. Q. A.

Q. A. Q. A. Q. A. Q. A.

19

Q. A. Q. A.

How can we address the objects inside the method Using reference variable ME What do you mean by Generalization and Specialization Generalization is factoring out common elements into more general class i.e. .superclass. Specialization requires the depth of experience in a particular domain. As and when we go up in the hierarchy, we are generalizing the class. As we do down the hierarchy, we go on adding special features to the component to make it specialized. A superclass is a generalization of its subclasses. The subclass in turn is a specialization of its superclasses.

Q. A. Q. A. Q. A. Q. A. Q. A. Q. A.

Can we have multiple inheritances in ABAP Objects No Can subclass remove any components from superclass No Why it is said Inheritance is a "one-sided relationship Subclasses know their direct superclasses, but (super) classes do not know their subclasses. Can we change the signature of methods which are redefine in subclass No, except constructor How to redefine the static method Static method cannot be redefine What is the visibility of protected section The visibility of these components lies between that of the public components (visible to all users, all subclasses, and the class itself), and private (visible only to the class itself). Protected components are visible to and can be used by all subclasses and the class itself. If a subclass add some new components, is it visible by superclass reference No Why is events used By triggering an event, an object or class announces a change of state, or that a certain state has been achieved. Which the transaction used to define global classes SE24 Can constructor or static method be abstract No What happen when we declare class as final

Q. A. Q. A. Q. A. Q. A. Q.

20

A. Q. A. Q. A. Q. A.

A final class cannot have subclasses, and can protect itself in this way against (uncontrolled) specialization. Can methods be both final and abstract. No Can class be both final and abstract. Yes. Only static components can be used. What is friend concepts In rare cases, classes have to work together so closely that they need access to their protected and private components. To avoid making these components available to all users, there is the concept of friendship between classes. To do this you use the FRIENDS additions to the CLASS statement, in which all classes and interfaces that are to be provided friendship are listed. Friends are allowed to access the protected and private components of the class providing the friendship and can always create instances of this class, regardless of the CREATE addition to the CLASS statement.

Q. A.

Which is the block executed before leaving the TRY-ENDTRY structure. CLEAN-UP

Difficult Questions Q. A. Q. A. Q. A. If a class inherit from superclass and if subclass reference calls a method of superclass and if method uses private attribute which are declare in both class, which attribute will it consider Methods that a subclass inherits from a superclass use the private attributes of the superclass, and not any private components of the subclass with the same names. Can a method defined in private section be redefined No, since a class's private methods are not visible and therefore cannot be redefined in subclasses If, for example, a superclass method M1 contains a call CALL METHOD [ME->]M2, and M2 is redefined in a subclass, calling M1 from an instance of the superclass, which method will it call. Calling M1 from an instance of the superclass will cause the original method M2 to be called, and calling M1 from an instance of the subclass will cause the redefined method M2 to be called. If we need to call the method of the same name in the immediate superclass, how to do Use pseudo-reference super. Why the constructor of the superclass should must be called within the constructor of the subclass. To ensure that objects are initialized correctly. Only the class itself, however, can initialize its own (private) components correctly; this task cannot be carried out by the subclass. Therefore it is essential that all (instance) constructors are called in an

Q. A. Q. A.

21

inheritance hierarchy (in the correct sequence). Q. A. Q. A. Q. A. Why it is possible for superclass reference to access the sub class components which are inherited by superclass This is possible because the subclass has inherited all components from the superclass and therefore has the same interface as the superclass What is narrowing cast or upcast The assignment of a subclass instance to a reference variable of the type "reference to superclass" is described as a narrowing cast. What do you mean by ?= cast operator With this kind of cast, a check is carried out at runtime to ensure that the current content of the source variable corresponds to the type requirements of the target variables. If it is, the assignment is carried out. Otherwise, an exception of the error class CX_SY_MOVE_CAST_ERROR is raised. How is interface components addressed in the class carrying out the implementation By prefixing the interface name, followed by a tilde (the Interface Resolution Operator): <interfacename>~<componentname>. What are steps required for triggering and handling the events - A class defines its: Instance events (using the EVENTS statement) Static events (using the CLASS-EVENTS statement) - A class or instance can trigger an event at runtime using the RAISE EVENT statement. - Classes or their instances that receive a message when an event is triggered at runtime and want to react to this event define event handler methods. Statement: [CLASS-]METHODS <handler_method> FOR EVENT <event> OF <classname>. - These classes or their instances are registered to one or more events at runtime. Statement: SET HANDLER <handler_method> FOR <reference>. (for instance events) SET HANDLER <handler_method>. (for static events) If two handler method are registered for an event, which handler method will be called Both. It will be called in the order which is first registered. Providing friendship is one-sided? Explain A class providing friendship is not automatically a friend of its friends. If a class providing friendship wants to access the non-public components of a friend, this friend has to explicitly provide friendship to it. Exception classes are derived from the which of the classes? Name them CX_NO_CHECK, CX_DYNAMIC_CHECK, or CX_STATIC_CHECK, themselves derived from the common superclass CX_ROOT. Which are the two predefined methods that are inherited by the other exception

Q. A. Q. A.

Q. A. Q. A.

Q. A. Q.

22

A.

classes. The GET_SOURCE_POSITION method returns the program name, include name (if relevant), and line number in the source code where the exception occurred. The GET_TEXT method returns an exception text of a class in the form of a string. How to create only one instance of a class Using singleton concept. Create private and final.

Q. A.

13. Module Programming


Medium questions Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Object Navigator Transaction SE80 Why do you specify Next screen attribute It allows you to specify the screen that should be processed after the current screen in a fixed sequence. What are the different screen types 1) Normal 2) Sub screen 3) Modal Dialog box 4) Selection Screen If you enter 0 (or no value) for the next screen, what will happen The system resumes processing from the point at which the screen was called once it finishes processing the screen itself 2 ways to create a screen. By using transaction SE80, call screen <nnnn>. Which are the 2 processors involved in module pool programming? ABAP processor controls the program flow within a module. The DYNP processor controls the flow logic and prepares data to be displayed on the screen What are the 4 events triggered in Module Pool programming 1) PBO 2) PAI 3) POH 4) POV Which is the field to store the current screen number Field SY-DYNNR In which section are Global fields declared TOP Include In which module can we changed the dynamically the attributes of elements on the screen PBO module How to change the dynamically modifiable attributes of the elements on the screen in a module at PBO LOOP AT SCREEN. . MODIFY SCREEN. . ENDLOOP.

23

Set attributes have the value 1; attributes that are not set have the value 0. Query on the fields of screen table e.g. SCREEN-NAME or SCREEN-GROUP1 to SCREEN-GROUP4. Q. A. Q. A. Q. A. At run time how can you temporarily override the static next screen Using the SET SCREEN <nnnn> statement To specify the next screen and leave the current screen in a single step, what is the statement used LEAVE TO SCREEN <nnnn> statement How to return to the statement following the CALL SCREEN statement from one screen You can use either SET SCREEN 0. LEAVE SCREEN. or LEAVE TO SCREEN 0. How to set a title for the screen SET TITLEBAR <title_name> WITH <&1> ... <&9>. How to create GUI status SET PF-STATUS 'STATUS'. What is status icon A status icon is an output field that contains an icon. You choose the relevant icon at run time. Icons allow you to indicate a status in your application. How the data exchange between screen and program takes place For a screen and its ABAP program to be able to communicate, the fields on the screen and the corresponding fields in the program must have identical names. a) After it has processed all of the modules in the PBO processing block, the system copies the contents of the fields in the ABAP work area to their corresponding fields in the screen work area. b) Before it processes the first module in the PAI processing block, the system copies the contents of the fields in the screen work area to their corresponding fields in the ABAP work area. Q. A. Q. A. Q. A. How to change the attributes of several screen elements simultaneously at run time Assign the elements to same group and query on the group name. Each element can be assigned to how many group 4 Is it possible that elements you have defined statically in the Screen Painter as invisible can be reactivated with SCREEN-ACTIVE = 1. If no, then what is the other way No, Instead use the statement SCREEN-INVISIBLE = 0.

Q. A. Q. A. Q. A. Q. A.

24

Q. A. Q. A. Q. A. Q. A.

Is it possible that elements you have statically defined as visible in the Screen Painter can dynamically be made invisible with SCREEN-ACTIVE = 0 Yes How to perform checks on a particular field To do this, use the FIELD <field_name> statement with the MODULE addition. When the system displays a screen, it automatically places the cursor in the first input field. If you want the cursor to appear in a different field, how to you do that? SET CURSOR FIELD <object_name> OFFSET <position>. How to create display icon In the ABAP program, define a field with the same name as the screen field using the TEXT field from the ICONS structure. At run time, this field contains the name of the icon you want to display. At run time, assign the required icon to this field using the ICON_CREATE function module What happen if warning or error message occurs in the module with field statement in addition If an error or warning message occurs during the module, the system sends the screen again, but without processing the PBO module. The message is displayed; only the field to which the check was applied is ready for input. How to check group of fields If you want to ensure that more than one field is ready for input following an error dialog, you must list all of the relevant fields in the FIELD statement, and include both that and the MODULE statement in a CHAIN ENDCHAIN block. What are different type of messages A, X, E, W, I, and S A - The processing terminates and the user must restart the transaction X - Like message type A, but with short dump MESSAGE_TYPE_X E - Processing is interrupted, and the user must correct the entry W - Processing is interrupted and the user can correct the entries I - Information Processing is interrupted, but continues when the user has confirmed the message (by selecting Enter). S - Information is displayed on the next screen What is the order of data transport from screen work area to ABAP work area The system transports data from screen fields into the ABAP fields with the same name in the PAI processing block. First, it transports all fields that are not contained in any FIELD statements. The remaining fields are transported when the system processed the relevant FIELD statement. What is the use of ON INPUT addition in a MODULE statement after FIELD The module is called only if the field contents have changed from their initial value. What is the use of ON CHAIN-INPUT addition The module is then called if the contents of at least one screen field within the CHAIN block have changed from their initial value.

Q. A.

Q. A.

Q. A.

Q. A.

Q. A. Q. A.

25

Q. A. Q. A. Q. A.

What is the use of ON REQUEST addition in a MODULE statement after FIELD The module is called only if the user enters a new value in that field. How to avoid the field input checks Implement the module with the AT EXIT-COMMAND addition. You may use the AT EXIT-COMMAND addition with only one module for each screen. What do you mean by subscreen area A subscreen area is a reserved rectangular area on a screen, in which you place another screen at run time. Subscreen areas may not contain any other screen elements. To use a subscreen, you create a second screen (with the type subscreen) and display it in the subscreen area you defined on the main screen. What are the restrictions apply to subscreens CALL SUBSCREEN is not allowed between LOOP and ENDLOOP or between CHAIN and ENDCHAIN. A subscreen may not have a named OK_CODE field. Object names must be unique within the set of all subscreens called in a single main screen. Subscreens may not contain a module with the AT EXIT-COMMAND addition. You cannot use the SET TITLEBAR, SET PF-STATUS, SET SCREEN, or LEAVE SCREEN statements in the modules of a subscreen.

Q. A.

Q. A.

How to call the subscreen and in which part it should be called To use a subscreen, you must call it in both the PBO and PAI sections of the flow logic of the main screen. The CALL SUBSCREEN <subarea> statement tells the system to execute the PBO and PAI processing blocks for the subscreen as components of the PBO and PAI of the main screen. If the subscreen is not in the same module pool as the main program, the global data of the main program is not available to the subscreen. How does data transfer takes place in this case? If you want to use subscreens in the screens of several different programs, you encapsulate the subscreens in a function group and use function modules to transport data between the program in which you want to use the subscreen and the function group. You pass data between the calling program and the function group using the interfaces of the function modules. What are the steps to create a tabstrip control Define the tab area. Define the tab titles and, if necessary, add further tab titles. Assign a subscreen area to each page element. How does data transfer takes place between ABAP program and Tabstrip Declare an object with the same name using the CONTROLS statement and TABSTRIP as the type

Q. A.

Q. A.

Q. A.

26

Q. A.

What happen if the tab title has function type space and what happen if it has P If the function type is ' (space), the PAI processing block is triggered when the user chooses that tab and the function code of the tab title is placed in the command field. If the function type is P, the user can scroll between different tab pages of the same type without triggering the PAI processing block. To program a tabstrip control to scroll locally at the front end, what has to be done Assign a separate subscreen area to each tab page. A subscreen will be sent to each of these when the screen is processed. Call all of the subscreens from the flow logic. Assign function type P to all of the tab titles. If you want the application program to process scrolling in a tabstrip control, what are the requirements to be met All of the tab pages must share a common subscreen area. All of the tab titles must have the function code type ' (space). In the flow logic, you must use a variable to call the screen that is to be displayed in the subscreen area. Where is the function code of the active tab title placed ACTIVETAB What are the steps to create a table control A table control area Table control fields How does data transfer takes place between ABAP program and Table control Declare an object with the same name using the CONTROLS statement and TABLEVIEW as the type. Use the DESCRIBE TABLE statement to find out the number of entries in the internal table and save this number in the lines field of the table control. In the PBO processing block, you must fill one line of the table control with the corresponding line from the internal table in each loop pass using statement LOOP AT <itab> INTO <wa_itab> WITH CONTROL <tc_name>. In the PAI processing block, you must pass the changes made in the table control back to the correct line of the internal table. The changed record index can be fetch from <control>-current_line

Q. A.

Q. A.

Q. A. Q. A. Q. A.

14. Enhancements
Easy questions Q. A. What is the difference between Modifications and Enhancements Changes to SAP Repository objects made at the customer site are known as Modifications. Creating Repository objects for individual customers that refer to objects

27

that already exist in the SAP Repository is known as Enhancements. Q. A. What do you mean by corrections and repairs Changes to an original are called corrections. They are recorded in a change request whose tasks have the type Development/correction. If, on the other hand, you change a copy (an object outside its own original system), the change is recorded in a task with the type Repair. Repairs to SAP objects are called modifications. Medium Questions Q. A. Q. A. Q. A. Which is the transaction used for maintaining Transaction variants (Personalization) SHD0 How to enhance tables By using append table By using Customizing Includes What is the difference between append table and customizing include Append structures allow you to enhance tables by adding fields to them that are not part of the standard. With append structures; customers can add their own fields to any table or structure they want. Append structures are created for use with a specific table. However, a table can have multiple append structures assigned to it. If it is known in advance that one of the tables or structures delivered by SAP needs to have customer-specific fields added to it, the SAP application developer includes these fields in the table using a Customizing include statement. The same Customizing include can be used in multiple tables or structures Q. A. Q. A. Q. A. What does text Enhancement includes Text enhancements include customer keywords and customer documentation of data elements. What does customer keywords consists of Short, Medium, Long, Header and Short Text of data element. What is the condition for keyword changes to take effect on a screen In order for keyword changes to take effect on a screen, SAP application programmers have to maintain the MOD attribute (keyword modification indicator) of the affected field accordingly in the Screen Painter field list. The MOD attribute must have one of the following values: SPACE: the keyword that best fits the field length 1: short keyword 2: medium keyword 3: long keyword

28

4: V: F:

keyword for header variable text transfer from the ABAP Dictionary fixed, no text transfer

If F is entered, then the keyword is fixed on the screen and cannot be replaced. In all other cases, screens that refer to that particular data element will show the changed keyword. Q. A. What is the difference between SMOD and CMOD The SAP application programmer creates SAP enhancements from function module exits, menu exits and screen exits. A management function is provided for this purpose (transaction code SMOD). Customers are given a catalog containing an overview of existing SAP enhancements. They can then combine the SAP enhancements they want into an enhancement project using transaction CMOD. Q. A. What are the steps for SAP Enhancement creation First, create an enhancement project and then choose the SAP enhancements that you want to use using transaction CMOD Next, edit your individual components using the project management function and document the entire enhancement project. Finally, activate the enhancement project. This activates all of the project's component parts. Q. A. What are the various types of customer exits / Enhancements Menu exits Screen exits Function module exits How is the function module exits called CALL CUSTOMER-FUNCTION 'nnn' where nnn is a three-digit number If you want to change an SAP Repository object, what information must be provided to the Workbench Organizer If you want to change an SAP Repository object, you must provide the Workbench Organizer with the following information: SSCR key Change request

Q. A. Q. A.

Difficult Questions Q. A. Where do we write our code in function module exit The function module, contains an INCLUDE statement for an include program that we have to create in the customer namespace

29

Q. A.

What should have been done in order for you to be able to implement menu exits? In order for you to be able to implement menu exits, SAP application programmers must equip the GUI interface with function codes that begin with a plus sign (+), assigns them to menus, and provides a function module exit. What are BTE Business Transaction Events (BTE) allow you to attach additional components, in the form of a function module, for the financial accounting components of R/3 What are the two type of interfaces used by BTE - Publish & Subscribe interfaces - Process interfaces How do we know SAP application provides BTE Search for function module that begins with OPEN_FI_PERFORM_ or OUTBOUND_CALL. Which is the transaction used for executing all of the actions necessary for using Business Transaction Events. FIBF Is BTE client-specific Yes Is Customer Exit client-specific No Difference between Customer Exit and BADI In Customer Exit, it in a project, there are many enhancement then we have to wait till all enhancement get over. Because unless whole project is activated, effect of enhancement does not take place in program. Whereas in BADI, there is no dependencies of other enhancement, irrespective of project activation. The effect of enhancement using BADI would be visible in program. In BADI, we used ABAP Objects. Therefore we can create multiple instances. Therefore it is reusable. Whereas this is not possible in Customer Exits.

Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A.

Q. A. Q. A. Q. A. Q.

What are the steps required for enhancement using BADI 1) Create BADI definition using SE18. Include all the methods definition. 2) Implement methods defined in BADI using SE19. How are multiple implementations possible for a single definition If we want multiple implementations for a single BADI definition, make sure the multiple use option for Type is checked. Which class and method is used for BADI instance Class cl_exithandler Method get_instance Types of attributes in BADI

30

A.

1)Reusable 2) Filter-dependent 3)Enhanceable How to implement filter dependent BADI Select the filter checkbox while defining BADI definition. Enter the data element you want as a filter type. When the enhancement method is called, a filter value must be passed to the interface. If BADI is filter- dependent , we must define an import parameter flt_val for each method. How does screen enhancement takes place using BADI Steps required in the application program to provide screen enhancement. In PBO Section. 1) Generate the Business Add-In class 2) Store a reference to this instance in the Add-In class. 3) Registering the instance 4)Making data available 5) Get the program name and screen number 6) Calling the subscreen In PAI Section. 1) Call the subscreen 2) Pass the data back Steps required for implementing screen enhancements 1) Create the implementation for the ADD-In definition. Specify the pgm containing the subscreen and screen number 2)Create the program specified in the Add-In implementation 3) Create the Subscreen screen 4)In PBO a) Get the instance of adapter class using method get_instance_for_subscreen. b) Get data from the adapter class 5)In PAI Write the changed data to the adapter class.

Q. A.

Q. A.

Q. A.

What are field exits Field exits are use to apply checks to a screen field Field exits are processed when the user leaves a screen that contains a field that refer to the data element containing a field exit Difference between global and local field exits Global field exits are not limited to a particular screen. Whereas local field exits are valid for one screen only. We can create only one global field exits or upto 36 local field exits for a data element but not both Can local field exit exist without global field exit No When do you opt for modification Customer exits are not available for all programs and screens within the R/3 standard applications. You can only use exits if they already exist within the SAP R/3 System.

Q. A.

Q. A. Q. A.

31

Otherwise you have to opt for modifications. Q. A. During the modification adjustment, use transaction is use to adjust ABAP Dictionary? Which objects are possible with this transaction SPDD. Objects Domains Data elements Tables SPAU Objects ABAP programs interfaces (menus) screens matchcode objects views lock objects.

15. Performance Optimization


Medium Questions Q. A. - Use of selection criteria - Use of the into table clause of select statement - Appending 2 internal tables - Use of binary search option - Modifying a group of lines of an internal table - Use of FOR ALL Entries - Proper structure of Where Clause - Using table buffering - Proper use of Inner Join Q. A. Explain Use of selection criteria Instead of selecting all the data and doing the processing during the selection, it is advisable to restrict the data to the selection criteria itself, rather than filtering it out using the ABAP code Select only those fields that are needed, so that the database server passes only a small amount of data back Not recommended Select * from zflight. Check: zflight-airln = LF and zflight-fligh = BW222. Endselect. What are the various performance tuning tips and tricks to make the ABAP programs efficient

32

Recommended Select f1 f2 f3 from zflight into (l1 l2 l3) where airln = LF and fligh = 222. Endselect. Q. A. Explain use of the into table clause of select statement Instead of appending one record at a time into an internal table, it is advisable to select all the records in a single shot. Not recommended Refresh: int_fligh. Select * from zflight into int_fligh. Append int_fligh. Clear int_fligh. Endselect. Recommended Refresh: int_fligh. Select * from zflight into table int_fligh. Q. A. Explain appending 2 internal tables Instead of using the normal loop-endloop approach for this kind of programming, use the variation of the append command. Care should be taken that the definition of both the internal tables should be identical. Not Recommended Loop at int_fligh1. Append int_fligh1 to int_fligh2. Endloop. Recommended Append lines of int_fligh1 to int_fligh2. Q. A. Explain Use of binary search option When a programmer uses the read command, the table is sequentially searched. This slows down the processing. Instead of this, use the binary search addition. The binary search algorithm helps faster search of a value in an internal table. It is advisable to sort the internal table before doing a binary search. Binary search repeatedly divides the search interval in half. If the value to be searched is less than the item in the middle of the interval, the search is narrowed to the lower half; otherwise the search is narrowed to the upper half. Not Recommended Read table int_fligh with key airln = LF. Recommended Sort int_fligh. Read table int_fligh with key airln = LF binary search. Q. A. Explain modifying a group of lines of an internal table Use the variations of the modify command to speed up this kind of processing.

33

Not recommended Loop at int_fligh. If int_fligh-flag is initial. Int_fligh-flag = X. Endif. Modify int_fligh. Endloop. Recommended Int_fligh-flag = X. Modify int_fligh transporting flag where flag is initial. Explain Use of FOR ALL Entries Outer join can be created using this addition to the where clause in a select statement. It speeds up the performance tremendously, but the cons of using this variation are listed below Duplicates are automatically removed from the resulting data set. Hence care should be taken that the unique key of the detail line items should be given in the select statement. If the table on which the For All Entries IN clause is based is empty, all rows are selected into the destination table. Hence it is advisable to check before-hand that the first table is not empty. If the table on which the For All Entries IN clause is based is very large, the performance will go down instead of improving. Hence attempt should be made to keep the table size to a moderate level. Not Recommended Loop at int_cntry. Select single * from zfligh into int_fligh where cntry = int_cntry-cntry. Append int_fligh. Endloop. Recommended Select * from zfligh appending table int_fligh For all entries in int_cntry Where cntry = int_cntry-cntry. Q. A. Explain proper structure of Where Clause When a base table has multiple indices, the where clause should be in the order of the index, either a primary or a secondary index. To choose an index, the optimizer checks the field names specified in the where clause and then uses an index that has the same order of the fields. One more tip is that if a table begins with MANDT, while an index does not, there is a high possibility that the optimizer might not use that index. In certain scenarios, it is advisable to check whether a new index can speed up the performance of a program. This will come handy in programs that access data from the finance tables. Q. Explain table buffering

Q. A.

34

A.

Use of buffered tables is recommended to improve the performance considerably. The buffer is bypassed while using the following statements Select distinct Select for update Order by, group by, having clause Joins Use the Bypass buffer addition to the select clause in order to explicitly bypass the buffer while selecting the data. Explain Proper use of Inner Join When multiple SAP tables are logically joined, it is always advisable to use inner join to read the data from them. This certainly reduces the load on the network. Let us take an example of 2 tables, zairln and zflight. The table zairln has the field airln, which is the airline code and the field lnnam, which is the name of the airline. The table zflight has the field airln, the airline code and other fields which hold the details of the flights that an airline operates. Since these 2 tables are logically joined by the airln field, it is advisable to use the inner join. Select a~airln a~lnnam b~fligh b~cntry into table int_airdet From zairln inner join zflight as b on a~airln = b~airln. In order to restrict the data as per the selection criteria, a where clause can be added to the above inner join.

Q. A.

Q. A.

What are the different tools provided by SAP for performance analysis 1)Run time analysis transaction SE30 This transaction gives all the analysis of an ABAP program with respect to the database and the non-database processing. 2)SQL Trace transaction ST05

16. Smartforms
Easy questions Q. A. Q. A. What is the transaction used Smartforms Is smartform client-dependant No

Medium Questions Q. How do we translate the text modules in smartform

35

A. Q. A.

Text modules are translated in other language thru transaction SE63. Can we keep the backup of smart form? How to upload and download the form? Yes we can keep the backup for a smartform. In the menu option Utilities we have the options for upload and download form, when we download the form it is stored in xml format. Is it possible to have multiple page formats in smartform Yes How to include logo in smartform Using SE78 import the logo in SAP system. Create graphics window in Smartform and give the name of logo to be uploaded How to debug a smartform There are two methods : - Can put hard coded break-point in the initialization part or any code node. - Go to se37(or SE80), give the name of function module of the smartform, and open it then Goto Main Program, you will find three includes: one for Global data, other for Function Module and the last include will have the code that we have done in smartform. Open that include and put the break-point wherever is needed by just selecting the breakpoint button on application toolbar. How many MAIN windows are possible in Smartforms One Where can we write ABAP Code Use Program node How many tabs are included in Form Interface Import, Export, Tables , Exceptions How to define address in Smartform Using address node and passing address number to it What is the difference between Main window and secondary window Secondary window has constant height. If text gets overflow in secondary window, it get truncated. Whereas in MAIN window, if its overflow, it introduces new page and continue from that point. Is it possible to migrate sapscript into smartform Yes

Q. A. Q. A. Q. A.

Q. A. Q. A. Q. A. Q. A. Q. A.

Q. A.

Difficult Questions Q. A. Q. What is the difference between template and table Table determine height at runtime while in template, we specify the height at design time How do we call smartform

36

A.

Use function module SSF_FUNCTION_MODULE_NAME and pass form name. It will return the function module name which will actually call the smartform. We can find the function module name in smartform from Environment menu. How to break the page Using Command break How can we incorporate IF-ELSE condition in Smartforms without writing code in program nodes. Use Alternate node How to convert smartform into PDF First pass no_dialog = X and getotf = X to control parameters while calling smartform. We will get the compress layout in the importing parameter job_output_info. Pass this to function module CONVERT_OTF_2_PDF.

Q. A. Q. A. Q. A.

17. SapScripts
Easy questions Q. A. Q. A. Q. A. What is the transaction used SE71 Is sapscript client-dependant Yes What are the components of Layout sets PAGES, Page windows, Header, Paragraph, Character String, Windows.

Medium Questions Q. A. Q. A. What is the table name that will contain all the script form names and print program names TNAPR In which case page break takes place SAPscript automatically inserts a page break when the main window of a page (MAIN) is full. You can use the NEW-PAGE command to force a page break in the text at any point you want one. How to set that a particular paragraph should not be split in two by a page break Use /: PROTECT : : /: ENDPROTECT How many main windows possible for a page? Does coding in each main window differs 99. No

Q. A.

Q. A.

37

Q. A. Q. A. Q. A. Q. A.

How are 99 main window identified? In which case is multiple main windows used? Each main window is assigned a consecutive identifying number (0...98), and the windows are filled in this order. It is basically used for printing labels How to call the next main window explicitly NEW-WINDOW command How to format date fields Using /: SET DATE MASK = 'date_mask' What is the use of The RESET control command The RESET control command is used to reset the numbering of an outline paragraph to its initial value. If the RESET command is not used, then the numbering of all outline paragraphs in a text will be continuous. If the name of an outline paragraph is specified in the RESET command, then its paragraph numbering and that of subordinate paragraphs will be reinitialized. How to include other text into current text Use the INCLUDE control command What is the use of ADDRESS - ENDADDRESS control command The ADDRESS - ENDADDRESS control command formats an address according to the postal convention of the recipient country defined in the COUNTRY parameter. Which control command is use to specify lines of text to be outputs always at the top of the main window. Use the TOP... ENDTOP control command How to print texts at the bottom of the window. Use /: BOTTOM : : /: ENDBOTTOM How to search for all sapscript name If you want to see the names of all the SAPScript forms in SAP then go to SE16 -> table "TADIR" PGMID is 'R3TR' OBJECT is FORM Execute to see names of all SAPScripts.

Q. A. Q. A. Q. A. Q. A.

Q. A.

Q. A.

Which are the function module used in SapScripts Open_Form Write_Form Close_form Control_form

38

Q. A. Q. A. Q. A.

Which is the transaction for Style Maintenance SE72 How to create standard text module SO10 What is the difference between start-form and open-form Start-form is used in case of multiple forms. Suppose if there are more than one form attached to a driver program, then open-form will open the pool which has the form name of first form along with language settings, printer settings etc, start-form will start the processing of first form, end-form will end the first form, again start-form will start the processing of second form, end-form will end the processing of second form and finally close-form will close the pool.

18. BDC
Easy questions Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Three phases of background processing Job Scheduling, Job Processing, and Job Overview. Transaction for scheduling a background job SM36 Function module used to trigger/raise event from within an ABAP program BP_EVENT_RAISE Methods by which a user event can be triggered ABAP function module BP_EVENT_RAISE, use external program SAPEVT. Transaction to display work processes for a particular application server SM50 Transaction for job overview SM37 Which are the function modules used to generate a background job from within the ABAP program These steps are accomplished by using three function modules: JOB_OPEN, JOB_SUBMIT, and JOB_CLOSE. What does the BDCDATA structure contain PROGRAM [CHAR 8] - Online program name. DYNPRO [NUMC 4] - Screen number. DYNBEGIN [CHAR 1] - Flag to indicate the start of a new screen. FNAM [CHAR 35] - Field name of a screen field to be filled with data. FVAL [CHAR 80] - The actual value to be filled into the specified screen field.

39

Q. A. Q. A. Q. A. Q. A.

If we want to simulate a user dialog in BDC, what general information is required Online program name, screen numbers, field names and field values. What are the various methods to perform Batch Input Batch Input session, Call transaction and Call Dialog. What are the function modules used to perform Batch Input BDC_OPEN_GROUP, BDC_INSERT and BDC_CLOSE_GROUP. In which processing mode does program RSBDCSUB schedule a Batch Input session Program RSBDCSUB schedules a session to be processed in the background. When this program is executed, a parameter screen prompts you for the session name.

Medium Questions Q. A. What is the most important point to remember while executing the BDC program An important point to remember is that executing a BDC program does not update the SAP database; instead, it creates a batch input session. The SAP database is updated when the batch input session is processed. What are the various methods to process Batch Input sessions Manually process batch input sessions in the Session Overview using transaction SM35. Execute program RSBDCSUB. With respect to timing, comment on Batch Input session method When dealing with batch input sessions, there is a timing issue involving the creation of a batch input session and the processing of a batch input session. The creation and processing of batch input sessions are distinct actions; therefore, they occur at different times. Between the time a batch input session is created and the time it is processed, changes may have been made to the SAP database. These changes may result in errors when processing the batch input session. Q. A. What is the main difference between Batch Input method and CALL TRANSACTION/CALL DIALOG. Two questions illustrate the main differences between creating a batch input session and using the CALL TRANSACTION/DIALOG: When is the SAP database updated? How are errors handled? When is the SAP database updated? If you create a batch input session in a BDC program, the SAP database is updated during the processing of the batch input session, not the execution of the BDC program.

Q. A.

Q. A.

40

If you use the CALL TRANSACTION or CALL DIALOG statement, the SAP database is updated during the execution of the batch input program. In other words, the timing issue we covered in the previous chapter is not an issue with these two alternatives because the database is updated during the execution of the batch input program. How are errors handled? If you create a batch input session in a BDC program, errors are handled automatically by the system during the processing of the batch input session. Errors are recorded in a log and the batch input session in error is kept. If you use the CALL TRANSACTION or CALL DIALOG statement, errors are not handled automatically by the system. Errors must be handled in the batch input program. Q. A. What are the various options when using the CALL TRANSACTION statement CALL TRANSACTION <transaction code> USING <bdc table> [MODE <display mode>] [UPDATE <update mode>] [MESSAGES INTO <mssg int. table>]. Q. A. The <bdc table> must be declared LIKE BDCDATA. The only required addition for batch input is USING. The other additions are only valid in conjunction with the USING addition. The <display mode> determines how the transaction will be processed: A (display all), E (display errors only), or N (no display). The default is A. The <update mode> determines how updating will occur: S (synchronous) or A (asynchronous). The default is A. Synchronous updating indicates that an update is completed for the transaction before processing returns to the calling program. Asynchronous updating indicates that processing returns to the calling program immediately after the transaction is completed, even before the update is completed. System messages issued during the transaction can be stored in the <mssg int. table>. This internal table must be declared LIKE BDCMSGCOLL.

What about error handling when using CALL TRANSACTION/CALL DIALOG Errors are not handled automatically by the system. Therefore, you must handle these errors in the batch input program. The value of SY-SUBRC indicates the success or failure of the transaction. What are some of the ways of handling errors Errors can be handled in many ways. Some of them include - Write an error report. - Send the record(s) in error to an error file. - Create a batch input session with the record(s) in error. Difference between synchronous and asynchronous mode of updating Synchronous updating indicates that an update is completed for the transaction before processing returns to the calling program. Asynchronous updating indicates that processing returns to the calling program immediately after the transaction is completed, even before the update is completed.

Q. A.

Q. A.

41

Q. A.

With respect to execution speed, comment on the difference between synchronous and asynchronous mode of updating Synchronous updating is slower than asynchronous updating because processing does not return to the calling program until the update is complete. Remember that the update mode when processing batch input sessions is always synchronous. With respect to return code (sy-subrc), comment on the difference between synchronous and asynchronous mode of updating The return code (SY-SUBRC) after synchronous updating indicates the success or failure of the actual update. The return code after asynchronous updating only indicates the success or failure of the transaction, not the update. What are the various options when using the CALL DIALOG statement CALL DIALOG <dialog module> USING <bdc table> [MODE <display mode>] . The <bdc table> must be declared LIKE BDCDATA. The only required addition for batch input is USING. The MODE addition is only valid in conjunction with the USING addition. The <display mode> determines how the dialog module will be processed: A (display all), E (display errors only), or N (no display). The default is A. Notice that an update mode is not specified with the CALL DIALOG statement. The update is not handled by the dialog module, but instead by the calling program. The COMMIT WORK statement is required in the calling program to update the database. Difference between CALL TRANSACTION and CALL DIALOG The main difference between the CALL TRANSACTION USING method and the CALL DIALOG method is the timing of the update to the SAP database. With the CALL TRANSACTION USING batch input method, an update occurs after each transaction is completed. With the CALL DIALOG batch input method, an update only occurs on the COMMIT WORK statement.

Q. A.

Q. A.

Q. A.

19. ALE/IDOC
Easy questions Q. A. Q. A. Q. A. What is an IDOC IDOCs are intermediate documents to hold the messages as a container. What is a message type It is a type of document for data that is exchanged between two systems. Where do we create segments and basic type WE31 and WE30 respectively

42

Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A. Q. A.

Where do we monitor the idoc WE02/WE05 Where do we create process code WE42 What is a process code A process code represents the function module that is used for the inbound and outbound process. Where do we test the idoc WE19. Where do we reprocess the idoc BD87. What is a segment A segment defines the format and structure of a data record. In which transaction code you would link idoc type to message type WE82 What are the different types of records in an IDOC It consists of three types of records: Control Record: An IDOC can contain only one control record. Data Record: An IDOC can contain one or many data records which contains applications. Status Record: An IDOC can contain one or many status records.

Q. A.

What do u mean by control record, data record, status record Control record It has a fixed predefined structure which is defined in DDIC as EDIDC. It contains information about IDOC such as: IDOC ID Sender ID Receiver ID IDOC type Message type Directions. Data record It contains the application data. It consists of segments that define format and structure of data record. Data record has predefined structure of DDIC as EDIDD that holds application data. SDATA field holds application data of length 1000 bytes. SEGNAM determines its structure. Status record It contains the status of the idoc (<50 outbound idoc,>50 inbound idoc). It contains two fields: IDOC ID and Status Information. It maintains the history and IDOC status. It contains the information whether the IDOC has processed

43

successfully. Standard DDIC table for status record is EDIDS. Q. A. Q. A. Where do we find the documentation for Idoc type or segment type WE60 What is an idoc type An idoc type defines the structure and format of the business document that needs to be exchanged between two systems.

Medium Questions Q. A. What is ALE ALE is SAP proprietary technology that enables data communications between two or more SAP R/3 systems and/or R/3 and external systems. When a new enterprise resource planning (ERP) solution such as R/3 is implemented, companies have to interface the ERP system with legacy systems or other ERP systems. ALE provides intelligent mechanisms where by clients can achieve integration as well as distribution of applications and data. ALE technology facilitates rapid application prototyping and application interface development, thus reducing implementation time. The ALE components are inherently integrated with SAP applications and are robust, leading to a highly reliable system. ALE comes with application distribution/integration scenarios as well as a set of tools, programs, data definitions, and methodologies that you can easily configure to get an interface up and running. Q. A. What is IDOC Processing There are two processes in IDOC, one is INBOUND PROCESS (IDOC coming to the system and its handling at various stages) and the other is OUTBOUND PROCESS (IDOC is send to other system). Separate ABAP programs are written for these 2 processes and different configuration settings are required for each one .Depending upon the triggering mechanism different programming approaches are used. OUTBOUND PROGRAMS handle the IDOC creation and INBOUND PROGRAMS handle the inbound IDOC and the data transfer from the IDOC to the database tables. When does the need for ABAP Programming arise -New IDOC was created - Depending upon the triggering mechanism i.e. change pointer, message control etc the programming technique changes and the type of process. -Existing IDOC was extended User Exits are used to populate data in new segments added and to read them back. -To enhance an existing process. -User Exits are used. How do you get output from IDOC Data in Idocs is stored in segments; the output from Idoc is obtained by reading the data stored in its respective segments.

Q. A.

Q. A.

44

Q. A. Q. A. Q. A.

What are the database tables used to maintain the changed document BDCP, BDCPS, CDHDR and CDPOS. What is the transaction code to activate change pointers BD61 Activate change pointers generally. BD50- Activate change pointers for message type. What is the Outbound ALE process The Outbound ALE process sends data (IDOC) to one or more SAP systems. Involves 4 steps: Identify the need for sending IDoc Generate Master IDoc Generate Communication IDoc Deliver the Communication IDoc What is the Inbound ALE process The inbound receives an IDoc and creates a document in the system. Involves 3 steps: Store the IDoc in the database Invokes the posting module Create the document What are the different methods of creating of an idoc(outbound) STANDALONE PROGRAM MASTER DATA DISTRIBUTION MESSAGE CONTROL CHANGE POINTERS EXTENDED IDOC REDUCED MESSAGE TYPE What are the configurations needed for creating a customized inbound idoc WE81(Create Message Type) WE31(Create Segments) WE30(Create basic type) BD51(Attach your Zfunction module) WE57(attach your zfunction module to message type and basic type) WE42(create process code and attach your zfunction module) WE20(Create Partner profiles) Before creating partner profiles we need to create a RFC destination (SM59) and Port creation(WE21)

Q. A.

Q. A.

Q. A.

Q. A. Q. A. Q.

What are the different types of filtering available for idoc Segment level and IDOC level. How do we configure the idoc filtering BD59(identifying the filter object) BD64(modifying the distribution model) How do we configure the segment filtering

45

A. Q. A.

BD56. What are the limitations of segment filtering We cannot filter for mandatory segments. We must maintain correct parent-child relationship, for example if we want to filter a parent segment we must ensure that all of its child segments are also filtered.

Q. A. Q. A. Q. A. Q. A.

What are the Transaction codes to distribute master data ( material master, customer master, vendor master) BD10, BD12, BD14 respectively. By which technology we handle the errors in ALE Workflow. Why do we require distribution model (Model View) Distribution model is used to model a distributed environment in which we specify messages exchanged between sending and receiving systems. What is the significance of program RSNAST00 It is used for applications that use message control to process idoc output.

Difficult Questions Q. A. How can we create / upload IDOC's from legacy system to SAP Third party tool Mercator may be used to convert Legacy files to Idoc format. Mercator provides an IDOC tree import facility, SAP provides the export facility. You can transfer the Idoc layouts from SAP to Mercator automatically and then map. What is RBDMIDOC It creates IDOC type from change pointers. This program is scheduled for the message type in periodic basis and calls internally the function module and sends IDOC to the receiver. Whenever a record is sent to receiver a change document flag is seen in the BDCP and BDCPS tp prevent from sending record once again, by checking status, status X means processed, status means not processed. What is the chance of getting maximum erroneous idocs (inbound or outbound) and why We will get maximum erroneous idocs in inbound because for inbound the data comes from other systems which may not be in the same format as in R/3, whereas for outbound we are sending the information to other system. What is the difference between extended idoc and reduced idoc type Extended idoc: we use extended idoc to extend the data which needs to be exchanged between two systems, means we are enhancing the information to the receiver system. Reduced idoc type: This is just the opposite of extended idoc where we reduce the information that needs to be exchanged between the systems. Q. When should ALE be used

Q. A.

Q. A.

Q. A.

46

A.

Besides the benefits of ALE there are also reasons not to distribute: The functional scope in a distributed environment is restricted. Not all functionality that is available in an integrated SAP system can be used with distributed systems in the standard yet. Although ALE provides tools to create new ALE business processes or to enhance existing business processes, this does involve additional expenditure. Each company needs some organizational standards and data harmonization. In a distributed environment fewer standards are required than on a single integrated system. However, in a distributed environment the maintenance of the standards and the data harmonization is more difficult than on a single system. The administration of decentralized systems is more expensive. Support and service costs for hardware and software in decentralized systems are higher than these costs in a single centralized system. ALE should be used in a company if the benefits of ALE for this company outweigh the reasons against distribution. For this you always need to carry out a company specific investigation, in which you also should consider the culture of the company. ALE is good for some companies but not for all.

Q. A.

Explain the Outbound process and Outbound program Outbound programs are used in outbound process to generate IDOCs. Their purpose is to extract the data from the tables and to fill the IDOC data records and the control record in the IDOC and pass it to the ALE layer for distribution to the receiving system. Depending upon the triggering mechanism (how and when the outbound program will be started) different techniques and interface is used for outbound program. What is Message control Application like PO(purchase order) creation use this technique , where the output type is linked to the application(Message control is a configurable cross application component which can be set in IMG .Such programs are created in the form of function modules and linked to the output type which is linked to the application. These have predefined interfaces. In outbound programs (function module) that use message control the key of the application document is passed to the function module which will read the data from the table depending upon the key passed (NAST structure) and fill the IDOC segments with the application data. The control record is also passed to the function module but is not fully filled, the remaining fields are filled and the control is passed back to the calling program which is RSNASTED and is invoked by the message control to process ALE and EDI output types and this program on receiving the IDOC data will create the physical IDOC in the system. The parameters passed to the function module are IMPORTING PARAMETERS OBJECT LIKE NAST It contains documents key. CONTROL_RECORD_IN LIKE EDIDC It contains the partially filled control record EXPORTING PARAMETER OBJECT_TYPE CONTROL_RECORD_OUT LIKE EDIDC TABLES

Q. A.

47

INT_EDID LIKE EDIDD The internal table used to fill the data records in the same order as they exist in the IDOC. The important parameters that should be filled in the custom function module are CONTROL_RECORD_OUT and INT_EDIDD .The OBJK field of the structure NAST contains the key of the application document. Q. A. What are Stand alone programs Generally used for Master Data transfer and as such depending upon the requirement can have different interfaces. The programs have a selection screen which has select options to select the objects, and parameters for specifying the recipient Logical System and the Message Type. Data is selected based on the specified objects from the tables and control record of type EDIDC is created and filled with important values like DIRECTION, DOCTP, RCVPRT, RCVPRN and MESTYP. Data is filled in an internal table of TYPE EDIDD according to segment definitions and in same order and the function module MASTER_IDOC_DISTRIBUTE is called passing the control record and the internal table containing IDOC data and importing an internal table consisting of control records for each communication IDOCS created. What is Change pointer Change Pointer table is read and checked if changes were made to important fields , if so the outbound program will be triggered automatically , these have predefined interfaces Describe the Basic structure of an OUTBOUND PROGRAM. The basic structure of all outbound programs is same. The CONTROL record which is of TYPE EDIDC has to be filled. It contains important fields like IDOCTP IDOC type MESTYP Message Type RCVPRN Receiving Partner (Destination) RCVPRT Partner Type (it is LS i.e. Logical System) The DATA RECORD internal table which is of TYPE EDIDD has to be filled in the same order as there are segments in the IDOC definition. It has 2 important fields which are to be filled ,these are SEGNAM Name of the segment SEGDATA Data in the segment and can be upto 1000 bytes. This field is corresponds to each data segment in the IDOC. e.g. DATA INT_EDIDD LIKE EDIDD OCCURS 0 WITH HEADER LINE. DATA W_SEGDATA LIKE zsegment "custom segment zsegment INT_EDIDD-SEGNAM = 'ZSEGMENT' W_SEGDATA-field1 = value "taken from some table W_SEGDATA-field2 = value "taken from some table INT_EDIDD-SEGDATA = W_SEGDATA APPEND INT_EDIDD This will fill the data record corresponding to the segment ZSEGMENT. For all segments the same steps will be repeated until all the data corresponding to all the segments in the idoc is filled in the internal table of type EDIDD.

Q. A.

Q. A.

48

There is only one control record and can be multiple data records in the idoc structure. Which data is to be extracted from the tables to be filled in EDIDD type internal table is determined in standalone programs from the objects which are specified in the selection screen and from the object key passed to the function module in case of message control and is taken from BDCP table in case of change pointers using function modules "CHANGE_POINTERS_READ" In case of stand alone programs and function modules based on change pointers method the function module "MASTER_IDOC_DISTRIBUTE" is used to send the IDOC to ALE layer for distribution, in case of message control it is handled automatically by the RSNASTED program invoked by the message control.

49

Вам также может понравиться