SAP OIIO_CHECK_MATERIAL Function Module for Check material of tank against material of order









OIIO_CHECK_MATERIAL is a standard oiio check material SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Check material of tank against material of order 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 oiio check material FM, simply by entering the name OIIO_CHECK_MATERIAL into the relevant SAP transaction such as SE37 or SE38.

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



Function OIIO_CHECK_MATERIAL 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 'OIIO_CHECK_MATERIAL'"Check material of tank against material of order
EXPORTING
* I_TANK_ID = "
I_KWMENG = "
I_MATNR = "
I_KUNNR = "
* I_POSNR = "
I_EDATU = "
* I_VRKME = "Sales unit
* I_OIPBL = "Business location identifier (IS-Oil MRN)

EXCEPTIONS
TANK_ID_NOT_VALID = 1 WRONG_MATERIAL = 2 SMALL_TANK = 3 DATE_OUT_OF_INTERVAL = 4 TANK_IS_BLOCKED = 5 TANK_VALIDITY_EXPIRED = 6
.



IMPORTING Parameters details for OIIO_CHECK_MATERIAL

I_TANK_ID -

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

I_KWMENG -

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

I_MATNR -

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

I_KUNNR -

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

I_POSNR -

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

I_EDATU -

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

I_VRKME - Sales unit

Data type: VBAP-VRKME
Optional: Yes
Call by Reference: Yes

I_OIPBL - Business location identifier (IS-Oil MRN)

Data type: KNA1-OIPBL
Optional: Yes
Call by Reference: Yes

EXCEPTIONS details

TANK_ID_NOT_VALID -

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

WRONG_MATERIAL -

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

SMALL_TANK -

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

DATE_OUT_OF_INTERVAL -

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

TANK_IS_BLOCKED -

Data type:
Optional: No
Call by Reference: Yes

TANK_VALIDITY_EXPIRED -

Data type:
Optional: No
Call by Reference: Yes

Copy and paste ABAP code example for OIIO_CHECK_MATERIAL 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_i_tank_id  TYPE ROIIO0100-TANK_ID, "   
lv_tank_id_not_valid  TYPE ROIIO0100, "   
lv_i_kwmeng  TYPE VBAP-KWMENG, "   
lv_wrong_material  TYPE VBAP, "   
lv_i_matnr  TYPE VBAP-MATNR, "   
lv_small_tank  TYPE VBAP, "   
lv_i_kunnr  TYPE KUWEV-KUNNR, "   
lv_date_out_of_interval  TYPE KUWEV, "   
lv_i_posnr  TYPE OIK37-POSNR, "   
lv_tank_is_blocked  TYPE OIK37, "   
lv_i_edatu  TYPE VBEP-EDATU, "   
lv_tank_validity_expired  TYPE VBEP, "   
lv_i_vrkme  TYPE VBAP-VRKME, "   
lv_i_oipbl  TYPE KNA1-OIPBL. "   

  CALL FUNCTION 'OIIO_CHECK_MATERIAL'  "Check material of tank against material of order
    EXPORTING
         I_TANK_ID = lv_i_tank_id
         I_KWMENG = lv_i_kwmeng
         I_MATNR = lv_i_matnr
         I_KUNNR = lv_i_kunnr
         I_POSNR = lv_i_posnr
         I_EDATU = lv_i_edatu
         I_VRKME = lv_i_vrkme
         I_OIPBL = lv_i_oipbl
    EXCEPTIONS
        TANK_ID_NOT_VALID = 1
        WRONG_MATERIAL = 2
        SMALL_TANK = 3
        DATE_OUT_OF_INTERVAL = 4
        TANK_IS_BLOCKED = 5
        TANK_VALIDITY_EXPIRED = 6
. " OIIO_CHECK_MATERIAL




ABAP code using 7.40 inline data declarations to call FM OIIO_CHECK_MATERIAL

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 TANK_ID FROM ROIIO0100 INTO @DATA(ld_i_tank_id).
 
 
"SELECT single KWMENG FROM VBAP INTO @DATA(ld_i_kwmeng).
 
 
"SELECT single MATNR FROM VBAP INTO @DATA(ld_i_matnr).
 
 
"SELECT single KUNNR FROM KUWEV INTO @DATA(ld_i_kunnr).
 
 
"SELECT single POSNR FROM OIK37 INTO @DATA(ld_i_posnr).
 
 
"SELECT single EDATU FROM VBEP INTO @DATA(ld_i_edatu).
 
 
"SELECT single VRKME FROM VBAP INTO @DATA(ld_i_vrkme).
 
"SELECT single OIPBL FROM KNA1 INTO @DATA(ld_i_oipbl).
 


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!