SAP Function Modules

RKE_PRICING_INTERFACE SAP Function module







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

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


Pattern for FM RKE_PRICING_INTERFACE - RKE PRICING INTERFACE





CALL FUNCTION 'RKE_PRICING_INTERFACE' "
  EXPORTING
*   i_plikz = '0'               " cest3-plikz
    i_stichtag =                " sy-datum
    i_kappl =                   " t681a-kappl
    i_kalsm =                   " t683-kalsm
    i_mengenfeld =              " dd03v-fieldname
*   i_storno = SPACE            " s007-shkzg
*   i_dialog = SPACE            " kedr_flag
    i_bwfkt =                   " tkeva01-bwfkt
*   i_kurst = 'M'               " tkevs-kurst
*   i_convert_indirect = SPACE  " kedr_flag
    i_tabname =                 " dd02v-tabname
*   i_overwrite = SPACE         " kedr_flag
    is_copa_item_input =        "
  IMPORTING
    es_copa_item_output =       "
    e_message_tab =             " rkea1_t_message_tab
  TABLES
    dbtab =                     "
*   wertkomp =                  " rkepr         Table of value fields
*   xt_item_bukrs =             "
  EXCEPTIONS
    NO_QUANTITY_UNIT = 1        "
    VALUATION_ERROR = 2         "
    .  "  RKE_PRICING_INTERFACE

ABAP code example for Function Module RKE_PRICING_INTERFACE





The ABAP code below is a full code listing to execute function module RKE_PRICING_INTERFACE 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_es_copa_item_output  TYPE STRING ,
ld_e_message_tab  TYPE RKEA1_T_MESSAGE_TAB ,
it_dbtab  TYPE STANDARD TABLE OF STRING,"TABLES PARAM
wa_dbtab  LIKE LINE OF it_dbtab ,
it_wertkomp  TYPE STANDARD TABLE OF RKEPR,"TABLES PARAM
wa_wertkomp  LIKE LINE OF it_wertkomp ,
it_xt_item_bukrs  TYPE STANDARD TABLE OF STRING,"TABLES PARAM
wa_xt_item_bukrs  LIKE LINE OF it_xt_item_bukrs .


DATA(ld_i_plikz) = some text here
DATA(ld_i_stichtag) = '20210129'.

SELECT single KAPPL
FROM T681A
INTO @DATA(ld_i_kappl).


SELECT single KALSM
FROM T683
INTO @DATA(ld_i_kalsm).


DATA(ld_i_mengenfeld) = some text here

DATA(ld_i_storno) = some text here
DATA(ld_i_dialog) = '20210129'.

SELECT single BWFKT
FROM TKEVA01
INTO @DATA(ld_i_bwfkt).


SELECT single KURST
FROM TKEVS
INTO @DATA(ld_i_kurst).

DATA(ld_i_convert_indirect) = '20210129'.

SELECT single TABNAME
FROM DD02V
INTO @DATA(ld_i_tabname).

DATA(ld_i_overwrite) = '20210129'.
DATA(ld_is_copa_item_input) = 'some text here'.

"populate fields of struture and append to itab
append wa_dbtab to it_dbtab.

"populate fields of struture and append to itab
append wa_wertkomp to it_wertkomp.

"populate fields of struture and append to itab
append wa_xt_item_bukrs to it_xt_item_bukrs. . CALL FUNCTION 'RKE_PRICING_INTERFACE' EXPORTING * i_plikz = ld_i_plikz i_stichtag = ld_i_stichtag i_kappl = ld_i_kappl i_kalsm = ld_i_kalsm i_mengenfeld = ld_i_mengenfeld * i_storno = ld_i_storno * i_dialog = ld_i_dialog i_bwfkt = ld_i_bwfkt * i_kurst = ld_i_kurst * i_convert_indirect = ld_i_convert_indirect i_tabname = ld_i_tabname * i_overwrite = ld_i_overwrite is_copa_item_input = ld_is_copa_item_input IMPORTING es_copa_item_output = ld_es_copa_item_output e_message_tab = ld_e_message_tab TABLES dbtab = it_dbtab * wertkomp = it_wertkomp * xt_item_bukrs = it_xt_item_bukrs EXCEPTIONS NO_QUANTITY_UNIT = 1 VALUATION_ERROR = 2 . " RKE_PRICING_INTERFACE
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 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_es_copa_item_output  TYPE STRING ,
ld_i_plikz  TYPE CEST3-PLIKZ ,
it_dbtab  TYPE STANDARD TABLE OF STRING ,
wa_dbtab  LIKE LINE OF it_dbtab,
ld_e_message_tab  TYPE RKEA1_T_MESSAGE_TAB ,
ld_i_stichtag  TYPE SY-DATUM ,
it_wertkomp  TYPE STANDARD TABLE OF RKEPR ,
wa_wertkomp  LIKE LINE OF it_wertkomp,
ld_i_kappl  TYPE T681A-KAPPL ,
it_xt_item_bukrs  TYPE STANDARD TABLE OF STRING ,
wa_xt_item_bukrs  LIKE LINE OF it_xt_item_bukrs,
ld_i_kalsm  TYPE T683-KALSM ,
ld_i_mengenfeld  TYPE DD03V-FIELDNAME ,
ld_i_storno  TYPE S007-SHKZG ,
ld_i_dialog  TYPE KEDR_FLAG ,
ld_i_bwfkt  TYPE TKEVA01-BWFKT ,
ld_i_kurst  TYPE TKEVS-KURST ,
ld_i_convert_indirect  TYPE KEDR_FLAG ,
ld_i_tabname  TYPE DD02V-TABNAME ,
ld_i_overwrite  TYPE KEDR_FLAG ,
ld_is_copa_item_input  TYPE STRING .


ld_i_plikz = some text here

"populate fields of struture and append to itab
append wa_dbtab to it_dbtab.
ld_i_stichtag = '20210129'.

"populate fields of struture and append to itab
append wa_wertkomp to it_wertkomp.

SELECT single KAPPL
FROM T681A
INTO ld_i_kappl.


"populate fields of struture and append to itab
append wa_xt_item_bukrs to it_xt_item_bukrs.

SELECT single KALSM
FROM T683
INTO ld_i_kalsm.


ld_i_mengenfeld = some text here

ld_i_storno = some text here
ld_i_dialog = '20210129'.

SELECT single BWFKT
FROM TKEVA01
INTO ld_i_bwfkt.


SELECT single KURST
FROM TKEVS
INTO ld_i_kurst.

ld_i_convert_indirect = '20210129'.

SELECT single TABNAME
FROM DD02V
INTO ld_i_tabname.

ld_i_overwrite = '20210129'.
ld_is_copa_item_input = '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 RKE_PRICING_INTERFACE or its description.