SAP Function Modules

ME_CHECK_CONDITION_COPY SAP Function module







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

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


Pattern for FM ME_CHECK_CONDITION_COPY - ME CHECK CONDITION COPY





CALL FUNCTION 'ME_CHECK_CONDITION_COPY' "
  EXPORTING
*   application = SPACE         " t685-kappl
*   dialog = 'X'                "
*   i_kondtyp = SPACE           " t685a-kntyp
*   i_position = SPACE          " ekpo-ebelp
    pricing_scheme =            " t683s-kalsm
*   tabelle = SPACE             " t682i-kotabnr
  IMPORTING
    copy_all =                  "
    copy_single =               "
    problem =                   "
  TABLES
    e_copy_tab =                "
    i_tkomv =                   " komv
  EXCEPTIONS
    NO_SUCCESS = 1              "
    .  "  ME_CHECK_CONDITION_COPY

ABAP code example for Function Module ME_CHECK_CONDITION_COPY





The ABAP code below is a full code listing to execute function module ME_CHECK_CONDITION_COPY 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_copy_all  TYPE STRING ,
ld_copy_single  TYPE STRING ,
ld_problem  TYPE STRING ,
it_e_copy_tab  TYPE STANDARD TABLE OF STRING,"TABLES PARAM
wa_e_copy_tab  LIKE LINE OF it_e_copy_tab ,
it_i_tkomv  TYPE STANDARD TABLE OF KOMV,"TABLES PARAM
wa_i_tkomv  LIKE LINE OF it_i_tkomv .


SELECT single KAPPL
FROM T685
INTO @DATA(ld_application).

DATA(ld_dialog) = 'some text here'.

SELECT single KNTYP
FROM T685A
INTO @DATA(ld_i_kondtyp).


SELECT single EBELP
FROM EKPO
INTO @DATA(ld_i_position).


SELECT single KALSM
FROM T683S
INTO @DATA(ld_pricing_scheme).


SELECT single KOTABNR
FROM T682I
INTO @DATA(ld_tabelle).


"populate fields of struture and append to itab
append wa_e_copy_tab to it_e_copy_tab.

"populate fields of struture and append to itab
append wa_i_tkomv to it_i_tkomv. . CALL FUNCTION 'ME_CHECK_CONDITION_COPY' EXPORTING * application = ld_application * dialog = ld_dialog * i_kondtyp = ld_i_kondtyp * i_position = ld_i_position pricing_scheme = ld_pricing_scheme * tabelle = ld_tabelle IMPORTING copy_all = ld_copy_all copy_single = ld_copy_single problem = ld_problem TABLES e_copy_tab = it_e_copy_tab i_tkomv = it_i_tkomv EXCEPTIONS NO_SUCCESS = 1 . " ME_CHECK_CONDITION_COPY
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "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_copy_all  TYPE STRING ,
ld_application  TYPE T685-KAPPL ,
it_e_copy_tab  TYPE STANDARD TABLE OF STRING ,
wa_e_copy_tab  LIKE LINE OF it_e_copy_tab,
ld_copy_single  TYPE STRING ,
ld_dialog  TYPE STRING ,
it_i_tkomv  TYPE STANDARD TABLE OF KOMV ,
wa_i_tkomv  LIKE LINE OF it_i_tkomv,
ld_problem  TYPE STRING ,
ld_i_kondtyp  TYPE T685A-KNTYP ,
ld_i_position  TYPE EKPO-EBELP ,
ld_pricing_scheme  TYPE T683S-KALSM ,
ld_tabelle  TYPE T682I-KOTABNR .


SELECT single KAPPL
FROM T685
INTO ld_application.


"populate fields of struture and append to itab
append wa_e_copy_tab to it_e_copy_tab.
ld_dialog = 'some text here'.

"populate fields of struture and append to itab
append wa_i_tkomv to it_i_tkomv.

SELECT single KNTYP
FROM T685A
INTO ld_i_kondtyp.


SELECT single EBELP
FROM EKPO
INTO ld_i_position.


SELECT single KALSM
FROM T683S
INTO ld_pricing_scheme.


SELECT single KOTABNR
FROM T682I
INTO ld_tabelle.

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