SAP CO_OCC_CONFIG_OVERWRITE_LOCK Function Module for NOTRANSL: Verhindert das Überschreiben einer Konfiguration
CO_OCC_CONFIG_OVERWRITE_LOCK is a standard co occ config overwrite lock SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for NOTRANSL: Verhindert das Überschreiben einer Konfiguration 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 co occ config overwrite lock FM, simply by entering the name CO_OCC_CONFIG_OVERWRITE_LOCK into the relevant SAP transaction such as SE37 or SE38.
Function Group: COOCC
Program Name: SAPLCOOCC
Main Program: SAPLCOOCC
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function CO_OCC_CONFIG_OVERWRITE_LOCK 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 'CO_OCC_CONFIG_OVERWRITE_LOCK'"NOTRANSL: Verhindert das Überschreiben einer Konfiguration.
EXPORTING
I_REG_DONE = "
I_AKTYP = "Activity Category in Transaction
I_AKTYP_PIC = "Activity Category in Transaction
I_ROOT_CUOBJ = "Configuration (Internal Object Number)
I_CREA_APL = "Application code, where the order/network was created
I_MAT_KZKFG = "Configurable Material
I_AUFNR = "Order Number
* I_AUFNR_SOURCE = ' ' "Reference Order Number
IMPORTING
E_REG_DONE = "
EXCEPTIONS
IMPORT_DATA_INCOMPLETE = 1 CONFIG_LOCK_FAILED = 2 NO_VALID_ROOT_CUOBJ = 3
IMPORTING Parameters details for CO_OCC_CONFIG_OVERWRITE_LOCK
I_REG_DONE -
Data type: COptional: No
Call by Reference: Yes
I_AKTYP - Activity Category in Transaction
Data type: RC27S-AKTYPOptional: No
Call by Reference: Yes
I_AKTYP_PIC - Activity Category in Transaction
Data type: RC27S-AKTYP_PICOptional: No
Call by Reference: Yes
I_ROOT_CUOBJ - Configuration (Internal Object Number)
Data type: CAUFVD-CUOBJOptional: No
Call by Reference: Yes
I_CREA_APL - Application code, where the order/network was created
Data type: CAUFVD-CREA_APLOptional: No
Call by Reference: Yes
I_MAT_KZKFG - Configurable Material
Data type: MSFCV-KZKFGOptional: No
Call by Reference: Yes
I_AUFNR - Order Number
Data type: CAUFVD-AUFNROptional: No
Call by Reference: Yes
I_AUFNR_SOURCE - Reference Order Number
Data type: CAUFVD-REFNRDefault: SPACE
Optional: Yes
Call by Reference: Yes
EXPORTING Parameters details for CO_OCC_CONFIG_OVERWRITE_LOCK
E_REG_DONE -
Data type: COptional: No
Call by Reference: Yes
EXCEPTIONS details
IMPORT_DATA_INCOMPLETE -
Data type:Optional: No
Call by Reference: Yes
CONFIG_LOCK_FAILED -
Data type:Optional: No
Call by Reference: Yes
NO_VALID_ROOT_CUOBJ -
Data type:Optional: No
Call by Reference: Yes
Copy and paste ABAP code example for CO_OCC_CONFIG_OVERWRITE_LOCK 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_e_reg_done | TYPE C, " | |||
| lv_i_reg_done | TYPE C, " | |||
| lv_import_data_incomplete | TYPE C, " | |||
| lv_i_aktyp | TYPE RC27S-AKTYP, " | |||
| lv_config_lock_failed | TYPE RC27S, " | |||
| lv_i_aktyp_pic | TYPE RC27S-AKTYP_PIC, " | |||
| lv_no_valid_root_cuobj | TYPE RC27S, " | |||
| lv_i_root_cuobj | TYPE CAUFVD-CUOBJ, " | |||
| lv_i_crea_apl | TYPE CAUFVD-CREA_APL, " | |||
| lv_i_mat_kzkfg | TYPE MSFCV-KZKFG, " | |||
| lv_i_aufnr | TYPE CAUFVD-AUFNR, " | |||
| lv_i_aufnr_source | TYPE CAUFVD-REFNR. " SPACE |
|   CALL FUNCTION 'CO_OCC_CONFIG_OVERWRITE_LOCK' "NOTRANSL: Verhindert das Überschreiben einer Konfiguration |
| EXPORTING | ||
| I_REG_DONE | = lv_i_reg_done | |
| I_AKTYP | = lv_i_aktyp | |
| I_AKTYP_PIC | = lv_i_aktyp_pic | |
| I_ROOT_CUOBJ | = lv_i_root_cuobj | |
| I_CREA_APL | = lv_i_crea_apl | |
| I_MAT_KZKFG | = lv_i_mat_kzkfg | |
| I_AUFNR | = lv_i_aufnr | |
| I_AUFNR_SOURCE | = lv_i_aufnr_source | |
| IMPORTING | ||
| E_REG_DONE | = lv_e_reg_done | |
| EXCEPTIONS | ||
| IMPORT_DATA_INCOMPLETE = 1 | ||
| CONFIG_LOCK_FAILED = 2 | ||
| NO_VALID_ROOT_CUOBJ = 3 | ||
| . " CO_OCC_CONFIG_OVERWRITE_LOCK | ||
ABAP code using 7.40 inline data declarations to call FM CO_OCC_CONFIG_OVERWRITE_LOCK
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 AKTYP FROM RC27S INTO @DATA(ld_i_aktyp). | ||||
| "SELECT single AKTYP_PIC FROM RC27S INTO @DATA(ld_i_aktyp_pic). | ||||
| "SELECT single CUOBJ FROM CAUFVD INTO @DATA(ld_i_root_cuobj). | ||||
| "SELECT single CREA_APL FROM CAUFVD INTO @DATA(ld_i_crea_apl). | ||||
| "SELECT single KZKFG FROM MSFCV INTO @DATA(ld_i_mat_kzkfg). | ||||
| "SELECT single AUFNR FROM CAUFVD INTO @DATA(ld_i_aufnr). | ||||
| "SELECT single REFNR FROM CAUFVD INTO @DATA(ld_i_aufnr_source). | ||||
| DATA(ld_i_aufnr_source) | = ' '. | |||
Search for further information about these or an SAP related objects