SAP HR_CONVERT_CURRENCY_RESULT Function Module for









HR_CONVERT_CURRENCY_RESULT is a standard hr convert currency result 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 hr convert currency result FM, simply by entering the name HR_CONVERT_CURRENCY_RESULT into the relevant SAP transaction such as SE37 or SE38.

Function Group: HRCR
Program Name: SAPLHRCR
Main Program: SAPLHRCR
Appliation area: P
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function HR_CONVERT_CURRENCY_RESULT 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 'HR_CONVERT_CURRENCY_RESULT'"
EXPORTING
COUNTRY_GROUPING = "Country Grouping
CONVERSION_DATE = "Key Date for Currency Conversion
FOREIGN_CURRENCY = "Foreign Currency
LOCAL_CURRENCY = "Local Currency (Target Currency)
* PERNR = "
* SEQNR = "

CHANGING
* P_BUFFER_T512W = "

TABLES
* RESULT_TABLE = "'RT' From Payroll Results
* CUMULATED_RESULT_TABLE = "'CRT' from Payroll Results
* SUBSEQUENT_TIME_TICKET_TABLE = "'LS' From Payroll Results
* ARREARS_TABLE = "'ARRRS' from Payroll Results
* DEDUCTION_TABLE = "'DDNTK' from Payroll Results
* AVERAGE_TABLE = "

EXCEPTIONS
INVALID_WAGETYPE = 1 ERROR_CONVERSION = 2
.



IMPORTING Parameters details for HR_CONVERT_CURRENCY_RESULT

COUNTRY_GROUPING - Country Grouping

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

CONVERSION_DATE - Key Date for Currency Conversion

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

FOREIGN_CURRENCY - Foreign Currency

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

LOCAL_CURRENCY - Local Currency (Target Currency)

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

PERNR -

Data type: P_PERNR
Optional: Yes
Call by Reference: Yes

SEQNR -

Data type: CDSEQ
Optional: Yes
Call by Reference: Yes

CHANGING Parameters details for HR_CONVERT_CURRENCY_RESULT

P_BUFFER_T512W -

Data type: PY12W_T_BUFFER
Optional: Yes
Call by Reference: Yes

TABLES Parameters details for HR_CONVERT_CURRENCY_RESULT

RESULT_TABLE - 'RT' From Payroll Results

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

CUMULATED_RESULT_TABLE - 'CRT' from Payroll Results

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

SUBSEQUENT_TIME_TICKET_TABLE - 'LS' From Payroll Results

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

ARREARS_TABLE - 'ARRRS' from Payroll Results

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

DEDUCTION_TABLE - 'DDNTK' from Payroll Results

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

AVERAGE_TABLE -

Data type: PC2AVERA
Optional: Yes
Call by Reference: Yes

EXCEPTIONS details

INVALID_WAGETYPE - A Wage Type is Not in Table T512W

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

ERROR_CONVERSION - A Wage Type Could Not Be Converted

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

Copy and paste ABAP code example for HR_CONVERT_CURRENCY_RESULT 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:
lt_result_table  TYPE STANDARD TABLE OF PC207, "   
lv_p_buffer_t512w  TYPE PY12W_T_BUFFER, "   
lv_country_grouping  TYPE T500L-MOLGA, "   
lv_invalid_wagetype  TYPE T500L, "   
lv_conversion_date  TYPE SY-DATUM, "   
lv_error_conversion  TYPE SY, "   
lt_cumulated_result_table  TYPE STANDARD TABLE OF PC22Y, "   
lv_foreign_currency  TYPE WAERS, "   
lt_subsequent_time_ticket_table  TYPE STANDARD TABLE OF PC20G, "   
lt_arrears_table  TYPE STANDARD TABLE OF PC22Z, "   
lv_local_currency  TYPE WAERS, "   
lv_pernr  TYPE P_PERNR, "   
lt_deduction_table  TYPE STANDARD TABLE OF PC23E, "   
lv_seqnr  TYPE CDSEQ, "   
lt_average_table  TYPE STANDARD TABLE OF PC2AVERA. "   

  CALL FUNCTION 'HR_CONVERT_CURRENCY_RESULT'  "
    EXPORTING
         COUNTRY_GROUPING = lv_country_grouping
         CONVERSION_DATE = lv_conversion_date
         FOREIGN_CURRENCY = lv_foreign_currency
         LOCAL_CURRENCY = lv_local_currency
         PERNR = lv_pernr
         SEQNR = lv_seqnr
    CHANGING
         P_BUFFER_T512W = lv_p_buffer_t512w
    TABLES
         RESULT_TABLE = lt_result_table
         CUMULATED_RESULT_TABLE = lt_cumulated_result_table
         SUBSEQUENT_TIME_TICKET_TABLE = lt_subsequent_time_ticket_table
         ARREARS_TABLE = lt_arrears_table
         DEDUCTION_TABLE = lt_deduction_table
         AVERAGE_TABLE = lt_average_table
    EXCEPTIONS
        INVALID_WAGETYPE = 1
        ERROR_CONVERSION = 2
. " HR_CONVERT_CURRENCY_RESULT




ABAP code using 7.40 inline data declarations to call FM HR_CONVERT_CURRENCY_RESULT

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 MOLGA FROM T500L INTO @DATA(ld_country_grouping).
 
 
"SELECT single DATUM FROM SY INTO @DATA(ld_conversion_date).
 
 
 
 
 
 
 
 
 
 
 


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!