SAP CBGL_DE00_VARIANTS_DET Function Module for NOTRANSL: EHS: Gen. Varianten ermitteln
CBGL_DE00_VARIANTS_DET is a standard cbgl de00 variants det 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: EHS: Gen. Varianten ermitteln 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 cbgl de00 variants det FM, simply by entering the name CBGL_DE00_VARIANTS_DET into the relevant SAP transaction such as SE37 or SE38.
Function Group: CBGL_DE00
Program Name: SAPLCBGL_DE00
Main Program: SAPLCBGL_DE00
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function CBGL_DE00_VARIANTS_DET 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 'CBGL_DE00_VARIANTS_DET'"NOTRANSL: EHS: Gen. Varianten ermitteln.
EXPORTING
I_LABEL_TYPE = "
* I_LESS_VARIANTS = ESP1_TRUE "
* I_MATNR = "Material Number
I_MTLS_RECN = "Identification Number
* I_NODG = ESP1_FALSE "
* I_FBSTATEDET = "Function Module for State Check at Label Generation
* I_STATECHECKMOD = "State Check Mode
* I_SUBID = "Specification
* I_FLG_TRP = TRUE "Contains Transport Symbols
IMPORTING
E_FLG_WARNING = "Warning Message Occurred
TABLES
I_VAL_AREAS_TAB = "EHS: Structure for Validity Areas
I_DG_REG_TAB = "EHS: Structure for Validity Areas
I_LABELSTOCK_TAB = "EHS: IOTAB Label Stock - Header
E_VARIANTS_TAB = "
E_PRIO_VARIANTS_TAB = "EHS: Variant Determination
* E_LWDG_TAB = "EHS: Structure for Validity Areas
* I_CVDDP_TAB = "EHS: Parameter Values for Report Shipping
EXCEPTIONS
NOT_FOUND = 1 INTERNAL_ERROR = 2
IMPORTING Parameters details for CBGL_DE00_VARIANTS_DET
I_LABEL_TYPE -
Data type: CBGLE_LTYPOptional: No
Call by Reference: Yes
I_LESS_VARIANTS -
Data type: ESEBOOLEDefault: ESP1_TRUE
Optional: Yes
Call by Reference: Yes
I_MATNR - Material Number
Data type: MATNROptional: Yes
Call by Reference: Yes
I_MTLS_RECN - Identification Number
Data type: ESERECNOptional: No
Call by Reference: Yes
I_NODG -
Data type: CBGLE_NODGDefault: ESP1_FALSE
Optional: Yes
Call by Reference: Yes
I_FBSTATEDET - Function Module for State Check at Label Generation
Data type: CBGLE_FB_STATE_CHECK_GENOptional: Yes
Call by Reference: Yes
I_STATECHECKMOD - State Check Mode
Data type: CBGLE_STATE_CHECK_MODEOptional: Yes
Call by Reference: Yes
I_SUBID - Specification
Data type: ESESUBIDOptional: Yes
Call by Reference: Yes
I_FLG_TRP - Contains Transport Symbols
Data type: CBGLE_TRPDefault: TRUE
Optional: Yes
Call by Reference: Yes
EXPORTING Parameters details for CBGL_DE00_VARIANTS_DET
E_FLG_WARNING - Warning Message Occurred
Data type: ESEBOOLEOptional: No
Call by Reference: Yes
TABLES Parameters details for CBGL_DE00_VARIANTS_DET
I_VAL_AREAS_TAB - EHS: Structure for Validity Areas
Data type: CCGLS_VALIDITY_AREASOptional: No
Call by Reference: Yes
I_DG_REG_TAB - EHS: Structure for Validity Areas
Data type: CCGLS_VALIDITY_AREASOptional: No
Call by Reference: Yes
I_LABELSTOCK_TAB - EHS: IOTAB Label Stock - Header
Data type: CCGLS_LSHDIOTOptional: No
Call by Reference: Yes
E_VARIANTS_TAB -
Data type: CCGLS_MPD_LABELSOptional: No
Call by Reference: Yes
E_PRIO_VARIANTS_TAB - EHS: Variant Determination
Data type: CCGLS_VAR_DETOptional: No
Call by Reference: Yes
E_LWDG_TAB - EHS: Structure for Validity Areas
Data type: CCGLS_VALIDITY_AREASOptional: Yes
Call by Reference: Yes
I_CVDDP_TAB - EHS: Parameter Values for Report Shipping
Data type: CVDDPOptional: Yes
Call by Reference: Yes
EXCEPTIONS details
NOT_FOUND -
Data type:Optional: No
Call by Reference: Yes
INTERNAL_ERROR -
Data type:Optional: No
Call by Reference: Yes
Copy and paste ABAP code example for CBGL_DE00_VARIANTS_DET 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_not_found | TYPE STRING, " | |||
| lv_i_label_type | TYPE CBGLE_LTYP, " | |||
| lv_e_flg_warning | TYPE ESEBOOLE, " | |||
| lt_i_val_areas_tab | TYPE STANDARD TABLE OF CCGLS_VALIDITY_AREAS, " | |||
| lt_i_dg_reg_tab | TYPE STANDARD TABLE OF CCGLS_VALIDITY_AREAS, " | |||
| lv_internal_error | TYPE CCGLS_VALIDITY_AREAS, " | |||
| lv_i_less_variants | TYPE ESEBOOLE, " ESP1_TRUE | |||
| lv_i_matnr | TYPE MATNR, " | |||
| lt_i_labelstock_tab | TYPE STANDARD TABLE OF CCGLS_LSHDIOT, " | |||
| lv_i_mtls_recn | TYPE ESERECN, " | |||
| lt_e_variants_tab | TYPE STANDARD TABLE OF CCGLS_MPD_LABELS, " | |||
| lv_i_nodg | TYPE CBGLE_NODG, " ESP1_FALSE | |||
| lt_e_prio_variants_tab | TYPE STANDARD TABLE OF CCGLS_VAR_DET, " | |||
| lt_e_lwdg_tab | TYPE STANDARD TABLE OF CCGLS_VALIDITY_AREAS, " | |||
| lv_i_fbstatedet | TYPE CBGLE_FB_STATE_CHECK_GEN, " | |||
| lt_i_cvddp_tab | TYPE STANDARD TABLE OF CVDDP, " | |||
| lv_i_statecheckmod | TYPE CBGLE_STATE_CHECK_MODE, " | |||
| lv_i_subid | TYPE ESESUBID, " | |||
| lv_i_flg_trp | TYPE CBGLE_TRP. " TRUE |
|   CALL FUNCTION 'CBGL_DE00_VARIANTS_DET' "NOTRANSL: EHS: Gen. Varianten ermitteln |
| EXPORTING | ||
| I_LABEL_TYPE | = lv_i_label_type | |
| I_LESS_VARIANTS | = lv_i_less_variants | |
| I_MATNR | = lv_i_matnr | |
| I_MTLS_RECN | = lv_i_mtls_recn | |
| I_NODG | = lv_i_nodg | |
| I_FBSTATEDET | = lv_i_fbstatedet | |
| I_STATECHECKMOD | = lv_i_statecheckmod | |
| I_SUBID | = lv_i_subid | |
| I_FLG_TRP | = lv_i_flg_trp | |
| IMPORTING | ||
| E_FLG_WARNING | = lv_e_flg_warning | |
| TABLES | ||
| I_VAL_AREAS_TAB | = lt_i_val_areas_tab | |
| I_DG_REG_TAB | = lt_i_dg_reg_tab | |
| I_LABELSTOCK_TAB | = lt_i_labelstock_tab | |
| E_VARIANTS_TAB | = lt_e_variants_tab | |
| E_PRIO_VARIANTS_TAB | = lt_e_prio_variants_tab | |
| E_LWDG_TAB | = lt_e_lwdg_tab | |
| I_CVDDP_TAB | = lt_i_cvddp_tab | |
| EXCEPTIONS | ||
| NOT_FOUND = 1 | ||
| INTERNAL_ERROR = 2 | ||
| . " CBGL_DE00_VARIANTS_DET | ||
ABAP code using 7.40 inline data declarations to call FM CBGL_DE00_VARIANTS_DET
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_less_variants) | = ESP1_TRUE. | |||
| DATA(ld_i_nodg) | = ESP1_FALSE. | |||
| DATA(ld_i_flg_trp) | = TRUE. | |||
Search for further information about these or an SAP related objects