SAP Function Modules

FM_COM_ITEM_SINGLE_MAINTAIN SAP Function module - Maintain Commitment Item







FM_COM_ITEM_SINGLE_MAINTAIN 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 FM_COM_ITEM_SINGLE_MAINTAIN into the relevant SAP transaction such as SE37 or SE80.

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


Pattern for FM FM_COM_ITEM_SINGLE_MAINTAIN - FM COM ITEM SINGLE MAINTAIN





CALL FUNCTION 'FM_COM_ITEM_SINGLE_MAINTAIN' "Maintain Commitment Item
  EXPORTING
    i_f_fmmd_fmci =             " fmmd_fmci
    i_f_fmmd_fmcit =            " fmmd_fmcit
    i_f_fmmd_fmzubsp =          " fmmd_fmzubsp  Assign Budget Structure Elements
*   i_t_hierarchy =             " fmmd_t_fmhici_small
*   i_flg_hierarchy_inp = SPACE  " fmdy-xfeld   Checkbox
    i_f_fmci_up_std =           " fmci
    i_flg_child =               " fmdy-xfeld    Checkbox
    i_mode =                    " fmdy-xfeld
    i_call_context =            " fmmd_call_context
*   i_flg_no_enqueue = SPACE    " fmdy-xfeld
  IMPORTING
    e_f_fmmd_fmci =             " fmmd_fmci
    e_f_fmmd_fmcit =            " fmmd_fmcit
    e_t_hierarchy =             " fmmd_t_fmhici_small
    e_f_fmmd_fmzubsp =          " fmmd_fmzubsp  Assign Budget Structure Elements
    e_flg_save =                " fmdy-xfeld
    e_flg_inherit =             " fmdy-xfeld
    e_status =                  " fmmd_ci_status  Status
  EXCEPTIONS
    INPUT_ERROR = 1             "               Incorrect input data
    NO_AUTHORITY = 2            "               Authorization missing
    FIPEX_EXISTENCE_MODE_CONFLICT = 3  "
    ENQUEUE = 4                 "
    USER_EXIT = 5               "
    HH_FICTR_NOT_FOUND = 6      "
    FIKRS_NOT_FOUND = 7         "
    ERROR_OCCURED = 8           "
    .  "  FM_COM_ITEM_SINGLE_MAINTAIN

ABAP code example for Function Module FM_COM_ITEM_SINGLE_MAINTAIN





The ABAP code below is a full code listing to execute function module FM_COM_ITEM_SINGLE_MAINTAIN 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_f_fmmd_fmci  TYPE FMMD_FMCI ,
ld_e_f_fmmd_fmcit  TYPE FMMD_FMCIT ,
ld_e_t_hierarchy  TYPE FMMD_T_FMHICI_SMALL ,
ld_e_f_fmmd_fmzubsp  TYPE FMMD_FMZUBSP ,
ld_e_flg_save  TYPE FMDY-XFELD ,
ld_e_flg_inherit  TYPE FMDY-XFELD ,
ld_e_status  TYPE FMMD_CI_STATUS .

DATA(ld_i_f_fmmd_fmci) = 'Check type of data required'.
DATA(ld_i_f_fmmd_fmcit) = 'Check type of data required'.
DATA(ld_i_f_fmmd_fmzubsp) = 'Check type of data required'.
DATA(ld_i_t_hierarchy) = 'Check type of data required'.

DATA(ld_i_flg_hierarchy_inp) = some text here
DATA(ld_i_f_fmci_up_std) = 'Check type of data required'.

DATA(ld_i_flg_child) = some text here

DATA(ld_i_mode) = some text here
DATA(ld_i_call_context) = 'Check type of data required'.

DATA(ld_i_flg_no_enqueue) = some text here . CALL FUNCTION 'FM_COM_ITEM_SINGLE_MAINTAIN' EXPORTING i_f_fmmd_fmci = ld_i_f_fmmd_fmci i_f_fmmd_fmcit = ld_i_f_fmmd_fmcit i_f_fmmd_fmzubsp = ld_i_f_fmmd_fmzubsp * i_t_hierarchy = ld_i_t_hierarchy * i_flg_hierarchy_inp = ld_i_flg_hierarchy_inp i_f_fmci_up_std = ld_i_f_fmci_up_std i_flg_child = ld_i_flg_child i_mode = ld_i_mode i_call_context = ld_i_call_context * i_flg_no_enqueue = ld_i_flg_no_enqueue IMPORTING e_f_fmmd_fmci = ld_e_f_fmmd_fmci e_f_fmmd_fmcit = ld_e_f_fmmd_fmcit e_t_hierarchy = ld_e_t_hierarchy e_f_fmmd_fmzubsp = ld_e_f_fmmd_fmzubsp e_flg_save = ld_e_flg_save e_flg_inherit = ld_e_flg_inherit e_status = ld_e_status EXCEPTIONS INPUT_ERROR = 1 NO_AUTHORITY = 2 FIPEX_EXISTENCE_MODE_CONFLICT = 3 ENQUEUE = 4 USER_EXIT = 5 HH_FICTR_NOT_FOUND = 6 FIKRS_NOT_FOUND = 7 ERROR_OCCURED = 8 . " FM_COM_ITEM_SINGLE_MAINTAIN
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 ELSEIF SY-SUBRC EQ 4. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 5. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 6. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 7. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 8. "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_f_fmmd_fmci  TYPE FMMD_FMCI ,
ld_i_f_fmmd_fmci  TYPE FMMD_FMCI ,
ld_e_f_fmmd_fmcit  TYPE FMMD_FMCIT ,
ld_i_f_fmmd_fmcit  TYPE FMMD_FMCIT ,
ld_e_t_hierarchy  TYPE FMMD_T_FMHICI_SMALL ,
ld_i_f_fmmd_fmzubsp  TYPE FMMD_FMZUBSP ,
ld_e_f_fmmd_fmzubsp  TYPE FMMD_FMZUBSP ,
ld_i_t_hierarchy  TYPE FMMD_T_FMHICI_SMALL ,
ld_e_flg_save  TYPE FMDY-XFELD ,
ld_i_flg_hierarchy_inp  TYPE FMDY-XFELD ,
ld_i_f_fmci_up_std  TYPE FMCI ,
ld_e_flg_inherit  TYPE FMDY-XFELD ,
ld_i_flg_child  TYPE FMDY-XFELD ,
ld_e_status  TYPE FMMD_CI_STATUS ,
ld_i_mode  TYPE FMDY-XFELD ,
ld_i_call_context  TYPE FMMD_CALL_CONTEXT ,
ld_i_flg_no_enqueue  TYPE FMDY-XFELD .

ld_i_f_fmmd_fmci = 'Check type of data required'.
ld_i_f_fmmd_fmcit = 'Check type of data required'.
ld_i_f_fmmd_fmzubsp = 'Check type of data required'.
ld_i_t_hierarchy = 'Check type of data required'.

ld_i_flg_hierarchy_inp = some text here
ld_i_f_fmci_up_std = 'Check type of data required'.

ld_i_flg_child = some text here

ld_i_mode = some text here
ld_i_call_context = 'Check type of data required'.

ld_i_flg_no_enqueue = some text here

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 FM_COM_ITEM_SINGLE_MAINTAIN or its description.