SAP Transactions Table and Transaction running ABAP Program
Developer can query SAP Transaction Codes table TSTC or use SE80 Object Navigator to find SAP transactions running specific ABAP program or report. This tutorial shows how to find the SAP transaction used to launch a particular ABAP program.
SAP Transaction Codes table TSTC
Using SE11 ABAP Data Browser transaction, SAP transparent table TSTC (SAP Transaction Codes) for basic transaction information.
Display the TSTC database table with Program Name PGMNA (data type is PROGRAM_ID) field filled with the ABAP program name.
And run the query.
As seen in below screenshot from the query output of SE11 for TSTC table, TCODE field displays the SAP transaction used to execute ABAP program in PGMNA field.
It is possible to find tcode by using below SELECT statement in your ABAP codes.
In following sample ABAP code, I query the TSTC SAP transactions table for a specific SAP standart ABAP report SAPMSUU0O for SU3 transaction. Some programs are used in more than one transaction with different screen numbers.
Of course the ABAP developer should consider to find the correct screen number in following sample to correctly launch the targeted SAP transaction code.
ABAP function module TH_CREATE_MODE will create a new session and launch the selected SAP transaction code by querying the TSTC SAP transactions table.
On the other hand, ABAP4_CALL_TRANSACTION ABAP function module enables ABAP programmer to launch the selected transaction code in the same session, in the same GUI.
SAP Transaction Code used to execute ABAP Program
Another way to identify the SAP transaction code used for executing an ABAP program is displaying ABAP program in SE80 Object Navigator tool.
Launch SE80 tcode.
Select Program and type the program name in Repository Browser tool and press Enter.
If a transaction is created for the ABAP program, it will be displayed in the Transactions folder as seen in above screenshot.