SAP CALL TRANSACTION USING ABAP Statements



Get Example source ABAP code based on a different SAP table
  


• USING CALL TRANSACTION

CALL TRANSACTION, USING
Short Reference

ABAP_SYNTAX
CALL TRANSACTION ta WITH$|WITHOUT AUTHORITY-CHECK
USING bdc_tab ${ ${$[MODE mode$] $[UPDATE upd$]$}
$| $[OPTIONS FROM opt$] $}
$[MESSAGES INTO itab$].

ABAP Addition
1 ... MODE mode
2 ... UPDATE upd
3 ... OPTIONS FROM opt
4 ... MESSAGES INTO itab

What does it do?
In the variant with the addition USING, the transaction is executed using a batch input table. The transaction is called as described under CALL TRANSACTION. The additions WITH$|WITHOUT AUTHORITY-CHECK are used to control the authorization check.
bdc_tab expects an internal table with the line type BDCDATA from the ABAP Dictionary. The additions control its processing.
When a transaction with the addition USING is called, the system field sy-binpt is set to the value X in the called program, and no other transaction can be called using this addition while this transaction is running.
In a program, a batch input table bdc_tab is the internal representation of a subset of a batch input session and must be filled accordingly. The structure BDCDATA has the components shown in the table below. ComponentMeaning PROGRAMName of the program of the called transaction DYNPRONumber of the dynpro to be processed DYNBEGINFlag for the start of a new dynpro (possible values are X and blank) FNAMName of a dynpro field to be filled or batch input control statement, for example to position the cursor FVALValue to be passed to the dynpro field or to the control statement
Using the content of the internal table bdc_tab, any number of screens of the called transaction can be provided with input and user actions.
System Fields sy-subrcMeaning 0The called transaction was processed successfully. < 1000Error in the called transaction. If a message was sent within the transaction, it can be received using the addition MESSAGES. 1001Processing error.



Latest notes:

Calling a transaction using a batch input table is actually not the same as executing batch input sessions in batch input. However, there is no exact dividing line between the two, since batch input-based frameworks, such as CATT, and batch input management sometimes also execute the statement CALL TRANSACTION USING internally. As a result, they can use certain options that are not available in genuine batch input.
The control options for a batch input table include the control options for batch input sessions in real batch input, and sometimes exceed them.
ABAP_HINT_END



Example ABAP Coding

Call of transaction SE24 in the executable example class CL_DEMO_CALL_TRANSACTION_BDC.
ABEXA 00084
ABAP_EXAMPLE_END
• MODE CALL TRANSACTION

ABAP Addition

What does it do?
The addition MODE determines the processing mode for processing. mode can be specified as a character-like data object whose content and effect are shown in the following table. If neither of the additions MODE or OPTIONS FROM are used, the effect is the same as if mode had the content A. modeEffect AProcessing with display of the screens EDisplay of screens only if an error occurs NProcessing without display of the screens. If a breakpoint is reached in one of the called transactions , processing is terminated with sy-subrc equal to 1001. Then, the field sy-msgty contains S, sy-msgid contains 00, sy-msgno contains 344, sy-msgv1 contains SAPMSSY3, and sy-msgv2 contains 0131. PProcessing without display of the screens. If a breakpoint is reached in one of the called transactions, the system branches to the ABAP Debugger. OthersAs for A.
• UPDATE CALL TRANSACTION

ABAP Addition

What does it do?
The addition UPDATE determines the update mode for processing. upd can be specified as a character-like data object whose content and effect are shown in the following table. If neither of the additions UPDATE or OPTIONS FROM are used, the effect is the same as if upd had the content A. updEffect AAsynchronous update. Updates of the called programs are executed in the same way as if the addition AND WAIT were not specified in the statement COMMIT WORK. SSynchronous update. Updates of the called programs are executed in the same way as if the addition AND WAIT were specified in the statement COMMIT WORK. LLocal updates. Updates of the called program are executed in the same way as if the statement SET UPDATE TASK LOCAL had been executed in it. OthersAs for A.



Latest notes:

This option is not available for execution of batch input sessions in batch input. Updates are always synchronous here.
ABAP_HINT_END
• OPTIONS FROM CALL TRANSACTION

ABAP Addition

What does it do?
The addition OPTIONS covers the functions of the additions MODE and UPDATE and provides further options for controlling the processing of the batch input table. The control parameters are specified in an opt structure of the type CTU_PARAMS from the ABAP Dictionary. The CTU_PARAMS structure has the components shown in the following table: ComponentMeaning DISMODEProcessing mode. Values as for the addition MODE . UPMODEUpdate mode for processing. Values as for the addition UPDATE. CATTMODE CATT mode for processing. While batch input is used mostly for data transfer, CATT processes are designed to be reusable tests of more complex transactions . Values: blank (no CATT mode), N (CATT without single screen control), A (CATT with single screen control). DEFSIZEFlag to indicate whether the screens of the called transaction are displayed in the standard screen size. Values: X (standard size), blank (current size). RACOMMITFlag to indicate whether the statement COMMIT WORK terminates processing or not. Values: blank ( COMMIT WORK terminates processing), X ( COMMIT WORK does not terminate processing). NOBINPTFlag for the system field sy-binpt. Values: blank (sy-binpt contains X in the called transaction), X (sy-binpt contains blank in the called transaction). NOBIENDFlag for the system field sy-binpt. Values: blank (sy-binpt contains X after the end of the data from the batch input table in the called transaction) X ( sy-binpt contains blank after the end of the data in the called transaction).
Without the addition OPTIONS FROM, the values set by the additions MODE or UPDATE or the default values specified there (A) apply to DISMODE and UPMODE. The other components are set to the value blank.
• MESSAGES INTO CALL TRANSACTION

ABAP Addition

What does it do?
Using this addition, all the messages sent during batch input processing are stored in an internal table itab of the line type BDCMSGCOLL from the ABAP Dictionary.

ABAP_EXAMPLE_ABEXA
Transaction Call, <(>BDC<)> Table
ABAP_EXAMPLE_END

Return to menu