SAP CUSE_TYPE_SEARCH Function Module for NOTRANSL: Einstieg zur Typenfindung









CUSE_TYPE_SEARCH is a standard cuse type search 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: Einstieg zur Typenfindung 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 cuse type search FM, simply by entering the name CUSE_TYPE_SEARCH into the relevant SAP transaction such as SE37 or SE38.

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



Function CUSE_TYPE_SEARCH 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 'CUSE_TYPE_SEARCH'"NOTRANSL: Einstieg zur Typenfindung
EXPORTING
IV_INSTANCE = "Configuration (Internal Object Number)
* IV_CHECK_MBOM = "
* IV_MATERIAL = "Material Number
* IV_DATE = "Date and Time, Current (Application Server) Date
* IV_PLANT = "Plant
* IV_COMPLETE = 'X' "
* IV_INTERNAL_CFG = "
* IT_CFG = "
* IS_PROFILE = "Additional Data for Configurable Objects
* IV_CLASS = "Class Number

IMPORTING
EV_TYPE = "Material Number
EV_INSTANCE = "Configuration (Internal Object Number)

TABLES
ET_TYPES = "Type matching

EXCEPTIONS
NOT_FOUND = 1 INTERNAL_ERROR = 2
.



IMPORTING Parameters details for CUSE_TYPE_SEARCH

IV_INSTANCE - Configuration (Internal Object Number)

Data type: INOB-CUOBJ
Optional: No
Call by Reference: No ( called with pass by value option)

IV_CHECK_MBOM -

Data type: C
Optional: Yes
Call by Reference: No ( called with pass by value option)

IV_MATERIAL - Material Number

Data type: MARA-MATNR
Optional: Yes
Call by Reference: No ( called with pass by value option)

IV_DATE - Date and Time, Current (Application Server) Date

Data type: SY-DATUM
Optional: Yes
Call by Reference: No ( called with pass by value option)

IV_PLANT - Plant

Data type: MARC-WERKS
Optional: Yes
Call by Reference: No ( called with pass by value option)

IV_COMPLETE -

Data type: C
Default: 'X'
Optional: Yes
Call by Reference: No ( called with pass by value option)

IV_INTERNAL_CFG -

Data type: C
Optional: Yes
Call by Reference: No ( called with pass by value option)

IT_CFG -

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

IS_PROFILE - Additional Data for Configurable Objects

Data type: CUCO
Optional: Yes
Call by Reference: No ( called with pass by value option)

IV_CLASS - Class Number

Data type: KLAH-CLASS
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXPORTING Parameters details for CUSE_TYPE_SEARCH

EV_TYPE - Material Number

Data type: MARA-MATNR
Optional: No
Call by Reference: No ( called with pass by value option)

EV_INSTANCE - Configuration (Internal Object Number)

Data type: INOB-CUOBJ
Optional: No
Call by Reference: No ( called with pass by value option)

TABLES Parameters details for CUSE_TYPE_SEARCH

ET_TYPES - Type matching

Data type: API_TYP01
Optional: No
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 CUSE_TYPE_SEARCH 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_ev_type  TYPE MARA-MATNR, "   
lt_et_types  TYPE STANDARD TABLE OF API_TYP01, "   
lv_not_found  TYPE API_TYP01, "   
lv_iv_instance  TYPE INOB-CUOBJ, "   
lv_iv_check_mbom  TYPE C, "   
lv_ev_instance  TYPE INOB-CUOBJ, "   
lv_iv_material  TYPE MARA-MATNR, "   
lv_internal_error  TYPE MARA, "   
lv_iv_date  TYPE SY-DATUM, "   
lv_iv_plant  TYPE MARC-WERKS, "   
lv_iv_complete  TYPE C, "   'X'
lv_iv_internal_cfg  TYPE C, "   
lv_it_cfg  TYPE IBCO2_VALUE_TAB, "   
lv_is_profile  TYPE CUCO, "   
lv_iv_class  TYPE KLAH-CLASS. "   

  CALL FUNCTION 'CUSE_TYPE_SEARCH'  "NOTRANSL: Einstieg zur Typenfindung
    EXPORTING
         IV_INSTANCE = lv_iv_instance
         IV_CHECK_MBOM = lv_iv_check_mbom
         IV_MATERIAL = lv_iv_material
         IV_DATE = lv_iv_date
         IV_PLANT = lv_iv_plant
         IV_COMPLETE = lv_iv_complete
         IV_INTERNAL_CFG = lv_iv_internal_cfg
         IT_CFG = lv_it_cfg
         IS_PROFILE = lv_is_profile
         IV_CLASS = lv_iv_class
    IMPORTING
         EV_TYPE = lv_ev_type
         EV_INSTANCE = lv_ev_instance
    TABLES
         ET_TYPES = lt_et_types
    EXCEPTIONS
        NOT_FOUND = 1
        INTERNAL_ERROR = 2
. " CUSE_TYPE_SEARCH




ABAP code using 7.40 inline data declarations to call FM CUSE_TYPE_SEARCH

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 MATNR FROM MARA INTO @DATA(ld_ev_type).
 
 
 
"SELECT single CUOBJ FROM INOB INTO @DATA(ld_iv_instance).
 
 
"SELECT single CUOBJ FROM INOB INTO @DATA(ld_ev_instance).
 
"SELECT single MATNR FROM MARA INTO @DATA(ld_iv_material).
 
 
"SELECT single DATUM FROM SY INTO @DATA(ld_iv_date).
 
"SELECT single WERKS FROM MARC INTO @DATA(ld_iv_plant).
 
DATA(ld_iv_complete) = 'X'.
 
 
 
 
"SELECT single CLASS FROM KLAH INTO @DATA(ld_iv_class).
 


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!