SAP TR_SYS_PARAMS_CONTEXT_MODULE Function Module for Determine System Name, Type, Change Option
TR_SYS_PARAMS_CONTEXT_MODULE is a standard tr sys params context module SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Determine System Name, Type, Change Option processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.
See here to view full function module documentation and code listing for tr sys params context module FM, simply by entering the name TR_SYS_PARAMS_CONTEXT_MODULE into the relevant SAP transaction such as SE37 or SE38.
Function Group: SCTS_SYSTEM_CONTEXT
Program Name: SAPLSCTS_SYSTEM_CONTEXT
Main Program:
Appliation area: S
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:
Function TR_SYS_PARAMS_CONTEXT_MODULE pattern details
In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.CALL FUNCTION 'TR_SYS_PARAMS_CONTEXT_MODULE'"Determine System Name, Type, Change Option.
EXPORTING
DUMMY = "
IMPORTING
SYSTEMEDIT = "System Change Option
SYSTEMNAME = "System Name, for example, C11
SYSTEMTYPE = "System Type, for example,'SAP' 'Customer'
SYSTEM_CLIENT_ED = "Change Option for Client-Dependent Customizing Objects
SYS_CLIINDDEP_ED = "Change Option for Repository Objects in Logon Client
SYSTEM_CLIENT_RO = "Client Role ('P' = Productive)
EV_SFW_BCSET_REC = "
EXCEPTIONS
NO_SYSTEMNAME = 1 NO_SYSTEMTYPE = 2
IMPORTING Parameters details for TR_SYS_PARAMS_CONTEXT_MODULE
DUMMY -
Data type: CHAR_LG_01Optional: No
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for TR_SYS_PARAMS_CONTEXT_MODULE
SYSTEMEDIT - System Change Option
Data type: TADIR-EDTFLAGOptional: No
Call by Reference: No ( called with pass by value option)
SYSTEMNAME - System Name, for example, C11
Data type: SY-SYSIDOptional: No
Call by Reference: No ( called with pass by value option)
SYSTEMTYPE - System Type, for example,'SAP' 'Customer'
Data type: SY-SYSIDOptional: No
Call by Reference: No ( called with pass by value option)
SYSTEM_CLIENT_ED - Change Option for Client-Dependent Customizing Objects
Data type: T000-CCCORACTIVOptional: No
Call by Reference: No ( called with pass by value option)
SYS_CLIINDDEP_ED - Change Option for Repository Objects in Logon Client
Data type: T000-CCNOCLIINDOptional: No
Call by Reference: No ( called with pass by value option)
SYSTEM_CLIENT_RO - Client Role ('P' = Productive)
Data type: T000-CCCATEGORYOptional: No
Call by Reference: No ( called with pass by value option)
EV_SFW_BCSET_REC -
Data type: T000-CCORIGCONTOptional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
NO_SYSTEMNAME - System name cannot be determined or invalid length
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
NO_SYSTEMTYPE - System type cannot be determined
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for TR_SYS_PARAMS_CONTEXT_MODULE Function Module
The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the newer method of declaring data variables on the fly. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8), which i why i have stuck to the origianl for this example.DATA: | ||||
lv_dummy | TYPE CHAR_LG_01, " | |||
lv_systemedit | TYPE TADIR-EDTFLAG, " | |||
lv_no_systemname | TYPE TADIR, " | |||
lv_systemname | TYPE SY-SYSID, " | |||
lv_no_systemtype | TYPE SY, " | |||
lv_systemtype | TYPE SY-SYSID, " | |||
lv_system_client_ed | TYPE T000-CCCORACTIV, " | |||
lv_sys_cliinddep_ed | TYPE T000-CCNOCLIIND, " | |||
lv_system_client_ro | TYPE T000-CCCATEGORY, " | |||
lv_ev_sfw_bcset_rec | TYPE T000-CCORIGCONT. " |
  CALL FUNCTION 'TR_SYS_PARAMS_CONTEXT_MODULE' "Determine System Name, Type, Change Option |
EXPORTING | ||
DUMMY | = lv_dummy | |
IMPORTING | ||
SYSTEMEDIT | = lv_systemedit | |
SYSTEMNAME | = lv_systemname | |
SYSTEMTYPE | = lv_systemtype | |
SYSTEM_CLIENT_ED | = lv_system_client_ed | |
SYS_CLIINDDEP_ED | = lv_sys_cliinddep_ed | |
SYSTEM_CLIENT_RO | = lv_system_client_ro | |
EV_SFW_BCSET_REC | = lv_ev_sfw_bcset_rec | |
EXCEPTIONS | ||
NO_SYSTEMNAME = 1 | ||
NO_SYSTEMTYPE = 2 | ||
. " TR_SYS_PARAMS_CONTEXT_MODULE |
ABAP code using 7.40 inline data declarations to call FM TR_SYS_PARAMS_CONTEXT_MODULE
The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8."SELECT single EDTFLAG FROM TADIR INTO @DATA(ld_systemedit). | ||||
"SELECT single SYSID FROM SY INTO @DATA(ld_systemname). | ||||
"SELECT single SYSID FROM SY INTO @DATA(ld_systemtype). | ||||
"SELECT single CCCORACTIV FROM T000 INTO @DATA(ld_system_client_ed). | ||||
"SELECT single CCNOCLIIND FROM T000 INTO @DATA(ld_sys_cliinddep_ed). | ||||
"SELECT single CCCATEGORY FROM T000 INTO @DATA(ld_system_client_ro). | ||||
"SELECT single CCORIGCONT FROM T000 INTO @DATA(ld_ev_sfw_bcset_rec). | ||||
Search for further information about these or an SAP related objects