SAP UJK_SCRIPT_LOGIC_EXECUTE Function Module for the main entry of script logic execution









UJK_SCRIPT_LOGIC_EXECUTE is a standard ujk script logic execute SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for the main entry of script logic execution 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 ujk script logic execute FM, simply by entering the name UJK_SCRIPT_LOGIC_EXECUTE into the relevant SAP transaction such as SE37 or SE38.

Function Group: UJK_SCRIPT_LOGIC
Program Name: SAPLUJK_SCRIPT_LOGIC
Main Program: SAPLUJK_SCRIPT_LOGIC
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function UJK_SCRIPT_LOGIC_EXECUTE 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 'UJK_SCRIPT_LOGIC_EXECUTE'"the main entry of script logic execution
EXPORTING
I_APPSET = "BPC: AppSet ID
* I_KEYDATE = SY-DATUM "BPC: DATE(YYYYMMDD)
* IS_BADI_PARAM = "UJK_S_BADI_PARAM
* I_SUPPRESS_ZERO = ABAP_TRUE "whether or not to write back zero data. 'Y' is Not to write.
* I_LOG_USER = "BPC: User ID
* I_LOG_APPLICATION = "BPC: Log Application ID
I_APPLICATION = "BPC: Application ID
I_USER = "BPC: User ID
I_LOGIC = "script files
* I_FILE_TYPE = 'LGX' "file types
* IT_CV = "Script Logic Current View
* I_MODULE = "BPC: Module ID
I_LGF = "BPC: Folder/Document Name
* I_MODE = "Running Mode of Script

IMPORTING
ET_LGX = "table used to save script logic files
E_FM_ERROR_MESSAGE = "BPC: Large string
ET_LOG = "log table
E_SP_WARNING = "BPC: Generic indicator
ET_ERROR_RECORDS = "BPC: Record Line - Table Type
ET_MESSAGE = "BPC: Messages
ES_WB_STATUS = "Write back returned status information

EXCEPTIONS
CX_UJ_STATIC_CHECK = 1
.



IMPORTING Parameters details for UJK_SCRIPT_LOGIC_EXECUTE

I_APPSET - BPC: AppSet ID

Data type: UJ_APPSET_ID
Optional: No
Call by Reference: Yes

I_KEYDATE - BPC: DATE(YYYYMMDD)

Data type: UJ_DATE
Default: SY-DATUM
Optional: Yes
Call by Reference: Yes

IS_BADI_PARAM - UJK_S_BADI_PARAM

Data type: UJK_S_BADI_PARAM
Optional: Yes
Call by Reference: Yes

I_SUPPRESS_ZERO - whether or not to write back zero data. 'Y' is Not to write.

Data type: UJ_FLG
Default: ABAP_TRUE
Optional: Yes
Call by Reference: Yes

I_LOG_USER - BPC: User ID

Data type: UJ_USER_ID
Optional: Yes
Call by Reference: Yes

I_LOG_APPLICATION - BPC: Log Application ID

Data type: UJ_APPL_ID
Optional: Yes
Call by Reference: Yes

I_APPLICATION - BPC: Application ID

Data type: UJ_APPL_ID
Optional: No
Call by Reference: Yes

I_USER - BPC: User ID

Data type: UJ_USER_ID
Optional: No
Call by Reference: Yes

I_LOGIC - script files

Data type: UJK_T_SCRIPT_LOGIC_SCRIPTTABLE
Optional: No
Call by Reference: Yes

I_FILE_TYPE - file types

Data type: UJ_FILE_TYPE
Default: 'LGX'
Optional: No
Call by Reference: Yes

IT_CV - Script Logic Current View

Data type: UJK_T_CV
Optional: Yes
Call by Reference: Yes

I_MODULE - BPC: Module ID

Data type: UJ_MODULE_ID
Optional: Yes
Call by Reference: Yes

I_LGF - BPC: Folder/Document Name

Data type: UJ_DOCNAME
Optional: No
Call by Reference: Yes

I_MODE - Running Mode of Script

Data type: UJ_RUN_MODE
Optional: Yes
Call by Reference: Yes

EXPORTING Parameters details for UJK_SCRIPT_LOGIC_EXECUTE

ET_LGX - table used to save script logic files

Data type: UJK_T_SCRIPT_LOGIC_SCRIPTTABLE
Optional: No
Call by Reference: Yes

E_FM_ERROR_MESSAGE - BPC: Large string

Data type: UJ_LARGE_STRING
Optional: No
Call by Reference: Yes

ET_LOG - log table

Data type: UJK_T_SINGLE_STRING
Optional: No
Call by Reference: Yes

E_SP_WARNING - BPC: Generic indicator

Data type: UJ_FLG
Optional: No
Call by Reference: Yes

ET_ERROR_RECORDS - BPC: Record Line - Table Type

Data type: UJF_T_RECLINE
Optional: No
Call by Reference: Yes

ET_MESSAGE - BPC: Messages

Data type: UJ0_T_MESSAGE
Optional: No
Call by Reference: Yes

ES_WB_STATUS - Write back returned status information

Data type: UJO_S_WB_STATUS
Optional: No
Call by Reference: Yes

EXCEPTIONS details

CX_UJ_STATIC_CHECK - CPM BPC Basis Exception w/ T100 Message (Statically Checked)

Data type:
Optional: No
Call by Reference: Yes

Copy and paste ABAP code example for UJK_SCRIPT_LOGIC_EXECUTE 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_et_lgx  TYPE UJK_T_SCRIPT_LOGIC_SCRIPTTABLE, "   
lv_i_appset  TYPE UJ_APPSET_ID, "   
lv_cx_uj_static_check  TYPE UJ_APPSET_ID, "   
lv_i_keydate  TYPE UJ_DATE, "   SY-DATUM
lv_is_badi_param  TYPE UJK_S_BADI_PARAM, "   
lv_i_suppress_zero  TYPE UJ_FLG, "   ABAP_TRUE
lv_i_log_user  TYPE UJ_USER_ID, "   
lv_i_log_application  TYPE UJ_APPL_ID, "   
lv_i_application  TYPE UJ_APPL_ID, "   
lv_e_fm_error_message  TYPE UJ_LARGE_STRING, "   
lv_et_log  TYPE UJK_T_SINGLE_STRING, "   
lv_i_user  TYPE UJ_USER_ID, "   
lv_i_logic  TYPE UJK_T_SCRIPT_LOGIC_SCRIPTTABLE, "   
lv_e_sp_warning  TYPE UJ_FLG, "   
lv_i_file_type  TYPE UJ_FILE_TYPE, "   'LGX'
lv_et_error_records  TYPE UJF_T_RECLINE, "   
lv_it_cv  TYPE UJK_T_CV, "   
lv_et_message  TYPE UJ0_T_MESSAGE, "   
lv_i_module  TYPE UJ_MODULE_ID, "   
lv_es_wb_status  TYPE UJO_S_WB_STATUS, "   
lv_i_lgf  TYPE UJ_DOCNAME, "   
lv_i_mode  TYPE UJ_RUN_MODE. "   

  CALL FUNCTION 'UJK_SCRIPT_LOGIC_EXECUTE'  "the main entry of script logic execution
    EXPORTING
         I_APPSET = lv_i_appset
         I_KEYDATE = lv_i_keydate
         IS_BADI_PARAM = lv_is_badi_param
         I_SUPPRESS_ZERO = lv_i_suppress_zero
         I_LOG_USER = lv_i_log_user
         I_LOG_APPLICATION = lv_i_log_application
         I_APPLICATION = lv_i_application
         I_USER = lv_i_user
         I_LOGIC = lv_i_logic
         I_FILE_TYPE = lv_i_file_type
         IT_CV = lv_it_cv
         I_MODULE = lv_i_module
         I_LGF = lv_i_lgf
         I_MODE = lv_i_mode
    IMPORTING
         ET_LGX = lv_et_lgx
         E_FM_ERROR_MESSAGE = lv_e_fm_error_message
         ET_LOG = lv_et_log
         E_SP_WARNING = lv_e_sp_warning
         ET_ERROR_RECORDS = lv_et_error_records
         ET_MESSAGE = lv_et_message
         ES_WB_STATUS = lv_es_wb_status
    EXCEPTIONS
        CX_UJ_STATIC_CHECK = 1
. " UJK_SCRIPT_LOGIC_EXECUTE




ABAP code using 7.40 inline data declarations to call FM UJK_SCRIPT_LOGIC_EXECUTE

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.

 
 
 
DATA(ld_i_keydate) = SY-DATUM.
 
 
DATA(ld_i_suppress_zero) = ABAP_TRUE.
 
 
 
 
 
 
 
 
 
DATA(ld_i_file_type) = 'LGX'.
 
 
 
 
 
 
 
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!