SAP Function Modules

QTY_SCHEDULE_HANDLING_MEPO SAP Function module - Qty.schedule (SD/MM agreements,contracts,Call-off) Exchange







QTY_SCHEDULE_HANDLING_MEPO is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name QTY_SCHEDULE_HANDLING_MEPO into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: OIAC
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM QTY_SCHEDULE_HANDLING_MEPO - QTY SCHEDULE HANDLING MEPO





CALL FUNCTION 'QTY_SCHEDULE_HANDLING_MEPO' "Qty.schedule (SD/MM agreements,contracts,Call-off) Exchange
  EXPORTING
*   i_asav = SPACE              " rseu1-func    Special function: ASAV,CHSQ,CHRQ
*   i_function = 'DISP'         " rseu1-func    Function to be processed like CHAN,CREA,DISP..
*   i_skip = SPACE              " c             Indicator to skip header detail screen (yes/no)
    i_vbap_ekpo =               " oia09h        Document header data from MM(EKPO..) SD(VBAP..)
*   i_oia09h =                  " oia09h        Header data from last export E_OIA09H (no write->call by REF)
*   i_call_from = SPACE         " c             Text call from (e.g. title)
*   i_qty_check = SPACE         " c
  IMPORTING
    e_fcode =                   " rseu1-func    Return function code (save or SPACE
    e_oia09h =                  " oia09h        Header data of Qty.schedule
  TABLES
    t_oia09 =                   " oia09         Qty.schedule scheduling lines
  EXCEPTIONS
    APPLICATION_NOT_VALID = 1   "               Applic. not valid for QS (no raise -> message)
    INDICATOR_NOT_VALID = 2     "               Contract/Call-off indic. (no raise -> message)
    PARAMETER_ERROR = 3         "               Other param. error i.e. plant (no raise -> msg.)
    .  "  QTY_SCHEDULE_HANDLING_MEPO

ABAP code example for Function Module QTY_SCHEDULE_HANDLING_MEPO





The ABAP code below is a full code listing to execute function module QTY_SCHEDULE_HANDLING_MEPO including all data declarations. The code uses 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 original method of declaring data variables up front. 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).

DATA:
ld_e_fcode  TYPE RSEU1-FUNC ,
ld_e_oia09h  TYPE OIA09H ,
it_t_oia09  TYPE STANDARD TABLE OF OIA09,"TABLES PARAM
wa_t_oia09  LIKE LINE OF it_t_oia09 .


DATA(ld_i_asav) = some text here

DATA(ld_i_function) = some text here
DATA(ld_i_skip) = 'Check type of data required'.
DATA(ld_i_vbap_ekpo) = 'Check type of data required'.
DATA(ld_i_oia09h) = 'Check type of data required'.
DATA(ld_i_call_from) = 'Check type of data required'.
DATA(ld_i_qty_check) = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_t_oia09 to it_t_oia09. . CALL FUNCTION 'QTY_SCHEDULE_HANDLING_MEPO' EXPORTING * i_asav = ld_i_asav * i_function = ld_i_function * i_skip = ld_i_skip i_vbap_ekpo = ld_i_vbap_ekpo * i_oia09h = ld_i_oia09h * i_call_from = ld_i_call_from * i_qty_check = ld_i_qty_check IMPORTING e_fcode = ld_e_fcode e_oia09h = ld_e_oia09h TABLES t_oia09 = it_t_oia09 EXCEPTIONS APPLICATION_NOT_VALID = 1 INDICATOR_NOT_VALID = 2 PARAMETER_ERROR = 3 . " QTY_SCHEDULE_HANDLING_MEPO
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 2. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 3. "Exception "Add code for exception here ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_e_fcode  TYPE RSEU1-FUNC ,
ld_i_asav  TYPE RSEU1-FUNC ,
it_t_oia09  TYPE STANDARD TABLE OF OIA09 ,
wa_t_oia09  LIKE LINE OF it_t_oia09,
ld_e_oia09h  TYPE OIA09H ,
ld_i_function  TYPE RSEU1-FUNC ,
ld_i_skip  TYPE C ,
ld_i_vbap_ekpo  TYPE OIA09H ,
ld_i_oia09h  TYPE OIA09H ,
ld_i_call_from  TYPE C ,
ld_i_qty_check  TYPE C .


ld_i_asav = some text here

"populate fields of struture and append to itab
append wa_t_oia09 to it_t_oia09.

ld_i_function = some text here
ld_i_skip = 'Check type of data required'.
ld_i_vbap_ekpo = 'Check type of data required'.
ld_i_oia09h = 'Check type of data required'.
ld_i_call_from = 'Check type of data required'.
ld_i_qty_check = 'Check type of data required'.

SAP Documentation for FM QTY_SCHEDULE_HANDLING_MEPO


This function module is called by purchasing document/contract maintenance OR sales document/contract maintenance. ...See here for full SAP fm documentation

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name QTY_SCHEDULE_HANDLING_MEPO or its description.