SAP RHPA_CALCULATION Function Module for









RHPA_CALCULATION is a standard rhpa calculation 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 rhpa calculation FM, simply by entering the name RHPA_CALCULATION into the relevant SAP transaction such as SE37 or SE38.

Function Group: RHPA
Program Name: SAPLRHPA
Main Program: SAPLRHPA
Appliation area: H
Release date: N/A
Mode(Normal, Remote etc): Remote-Enabled
Update:



Function RHPA_CALCULATION 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 'RHPA_CALCULATION'"
EXPORTING
PLVAR = "
OBJID = "
* CALC_INIT = ' ' "
* APP_ATTRIBUTES = "Appraisal attributes

TABLES
* APPRAISERS = "Appraiser
* APPRAISEES = "Appraisee
APP_PT1045 = "
* ERR_APP_PT1045 = "
* NEW_CALCULATED = "

EXCEPTIONS
ERROR_DURING_CALCULATION = 1
.



IMPORTING Parameters details for RHPA_CALCULATION

PLVAR -

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

OBJID -

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

CALC_INIT -

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

APP_ATTRIBUTES - Appraisal attributes

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

TABLES Parameters details for RHPA_CALCULATION

APPRAISERS - Appraiser

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

APPRAISEES - Appraisee

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

APP_PT1045 -

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

ERR_APP_PT1045 -

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

NEW_CALCULATED -

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

EXCEPTIONS details

ERROR_DURING_CALCULATION -

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

Copy and paste ABAP code example for RHPA_CALCULATION 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_plvar  TYPE P1000-PLVAR, "   
lt_appraisers  TYPE STANDARD TABLE OF HRPE_APPRAISORS, "   
lv_error_during_calculation  TYPE HRPE_APPRAISORS, "   
lv_objid  TYPE P1000-OBJID, "   
lt_appraisees  TYPE STANDARD TABLE OF HRPE_APPRAISEES, "   
lv_calc_init  TYPE CHAR1, "   ' '
lt_app_pt1045  TYPE STANDARD TABLE OF PT1045_EXT, "   
lv_app_attributes  TYPE DYNP_RHPA, "   
lt_err_app_pt1045  TYPE STANDARD TABLE OF PT1045_EXT, "   
lt_new_calculated  TYPE STANDARD TABLE OF PT1045_EXT. "   

  CALL FUNCTION 'RHPA_CALCULATION'  "
    EXPORTING
         PLVAR = lv_plvar
         OBJID = lv_objid
         CALC_INIT = lv_calc_init
         APP_ATTRIBUTES = lv_app_attributes
    TABLES
         APPRAISERS = lt_appraisers
         APPRAISEES = lt_appraisees
         APP_PT1045 = lt_app_pt1045
         ERR_APP_PT1045 = lt_err_app_pt1045
         NEW_CALCULATED = lt_new_calculated
    EXCEPTIONS
        ERROR_DURING_CALCULATION = 1
. " RHPA_CALCULATION




ABAP code using 7.40 inline data declarations to call FM RHPA_CALCULATION

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 PLVAR FROM P1000 INTO @DATA(ld_plvar).
 
 
 
"SELECT single OBJID FROM P1000 INTO @DATA(ld_objid).
 
 
DATA(ld_calc_init) = ' '.
 
 
 
 
 


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!