SAP COPA_FIELDS_MOVE_OR_CONVERT Function Module for









COPA_FIELDS_MOVE_OR_CONVERT is a standard copa fields move or convert SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used to perform a specific ABAP function and below is the pattern details, 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 copa fields move or convert FM, simply by entering the name COPA_FIELDS_MOVE_OR_CONVERT into the relevant SAP transaction such as SE37 or SE38.

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



Function COPA_FIELDS_MOVE_OR_CONVERT 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 'COPA_FIELDS_MOVE_OR_CONVERT'"
EXPORTING
I_ERKRS = "
* I_BWFKT = '01' "
* I_VERSI = "
I_ITEM = "
I_FOREIGN_CURRENCY = "
I_LOCAL_CURRENCY = "
* I_RATE = "
* I_CONVERT_TO = 'L' "
IT_FIELDS = "

CHANGING
X_ITEM = "

TABLES
* IT_FIELDTAB = "
.




Customer Function user exits

Below is a list of CUSTOMER FUNCTION exit user exits that are available within this program and maybe relevant for this FM.
EXIT_SAPLKECU_001 User Exit for Determining the Exchange Rate Type

IMPORTING Parameters details for COPA_FIELDS_MOVE_OR_CONVERT

I_ERKRS -

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

I_BWFKT -

Data type: TKEVA01-BWFKT
Default: '01'
Optional: Yes
Call by Reference: No ( called with pass by value option)

I_VERSI -

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

I_ITEM -

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

I_FOREIGN_CURRENCY -

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

I_LOCAL_CURRENCY -

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

I_RATE -

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

I_CONVERT_TO -

Data type:
Default: 'L'
Optional: Yes
Call by Reference: No ( called with pass by value option)

IT_FIELDS -

Data type: RKEI1_YT_FIELD
Optional: No
Call by Reference: Yes

CHANGING Parameters details for COPA_FIELDS_MOVE_OR_CONVERT

X_ITEM -

Data type:
Optional: No
Call by Reference: Yes

TABLES Parameters details for COPA_FIELDS_MOVE_OR_CONVERT

IT_FIELDTAB -

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

Copy and paste ABAP code example for COPA_FIELDS_MOVE_OR_CONVERT 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_x_item  TYPE STRING, "   
lv_i_erkrs  TYPE TKEB-ERKRS, "   
lt_it_fieldtab  TYPE STANDARD TABLE OF RKEA1_FIELDTAB, "   
lv_i_bwfkt  TYPE TKEVA01-BWFKT, "   '01'
lv_i_versi  TYPE TKEVS-VERSI, "   
lv_i_item  TYPE TKEVS, "   
lv_i_foreign_currency  TYPE CEST1-FRWAE, "   
lv_i_local_currency  TYPE RKEA1_V_CURR-WAERS, "   
lv_i_rate  TYPE CEST1-KURSF, "   
lv_i_convert_to  TYPE CEST1, "   'L'
lv_it_fields  TYPE RKEI1_YT_FIELD. "   

  CALL FUNCTION 'COPA_FIELDS_MOVE_OR_CONVERT'  "
    EXPORTING
         I_ERKRS = lv_i_erkrs
         I_BWFKT = lv_i_bwfkt
         I_VERSI = lv_i_versi
         I_ITEM = lv_i_item
         I_FOREIGN_CURRENCY = lv_i_foreign_currency
         I_LOCAL_CURRENCY = lv_i_local_currency
         I_RATE = lv_i_rate
         I_CONVERT_TO = lv_i_convert_to
         IT_FIELDS = lv_it_fields
    CHANGING
         X_ITEM = lv_x_item
    TABLES
         IT_FIELDTAB = lt_it_fieldtab
. " COPA_FIELDS_MOVE_OR_CONVERT




ABAP code using 7.40 inline data declarations to call FM COPA_FIELDS_MOVE_OR_CONVERT

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 ERKRS FROM TKEB INTO @DATA(ld_i_erkrs).
 
 
"SELECT single BWFKT FROM TKEVA01 INTO @DATA(ld_i_bwfkt).
DATA(ld_i_bwfkt) = '01'.
 
"SELECT single VERSI FROM TKEVS INTO @DATA(ld_i_versi).
 
 
"SELECT single FRWAE FROM CEST1 INTO @DATA(ld_i_foreign_currency).
 
"SELECT single WAERS FROM RKEA1_V_CURR INTO @DATA(ld_i_local_currency).
 
"SELECT single KURSF FROM CEST1 INTO @DATA(ld_i_rate).
 
DATA(ld_i_convert_to) = 'L'.
 
 


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!