SAP RP_GET_REMAINING_HOLIDAY Function Module for









RP_GET_REMAINING_HOLIDAY is a standard rp get remaining holiday 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 rp get remaining holiday FM, simply by entering the name RP_GET_REMAINING_HOLIDAY into the relevant SAP transaction such as SE37 or SE38.

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



Function RP_GET_REMAINING_HOLIDAY 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 'RP_GET_REMAINING_HOLIDAY'"
EXPORTING
* DATUM = SY-DATUM "Key date for determining remaining leave
PERNR = "Personnel number
URLJJ = "Leave year

TABLES
UREST = "Remaining leave table
X0005 = "Leave entitlement table
X0083 = "Leave compensation table

EXCEPTIONS
MISSING_PERSONNEL_NUMBER = 1 NO_LEAVE_ENTITLEMENT_FOUND = 2
.



IMPORTING Parameters details for RP_GET_REMAINING_HOLIDAY

DATUM - Key date for determining remaining leave

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

PERNR - Personnel number

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

URLJJ - Leave year

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

TABLES Parameters details for RP_GET_REMAINING_HOLIDAY

UREST - Remaining leave table

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

X0005 - Leave entitlement table

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

X0083 - Leave compensation table

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

EXCEPTIONS details

MISSING_PERSONNEL_NUMBER - Personnel no. missing

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

NO_LEAVE_ENTITLEMENT_FOUND - No remaining leave found

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

Copy and paste ABAP code example for RP_GET_REMAINING_HOLIDAY 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_datum  TYPE SY-DATUM, "   SY-DATUM
lt_urest  TYPE STANDARD TABLE OF PI005, "   
lv_missing_personnel_number  TYPE PI005, "   
lv_pernr  TYPE PERNR-PERNR, "   
lt_x0005  TYPE STANDARD TABLE OF P0005, "   
lv_no_leave_entitlement_found  TYPE P0005, "   
lv_urljj  TYPE P0005-URLJJ, "   
lt_x0083  TYPE STANDARD TABLE OF P0083. "   

  CALL FUNCTION 'RP_GET_REMAINING_HOLIDAY'  "
    EXPORTING
         DATUM = lv_datum
         PERNR = lv_pernr
         URLJJ = lv_urljj
    TABLES
         UREST = lt_urest
         X0005 = lt_x0005
         X0083 = lt_x0083
    EXCEPTIONS
        MISSING_PERSONNEL_NUMBER = 1
        NO_LEAVE_ENTITLEMENT_FOUND = 2
. " RP_GET_REMAINING_HOLIDAY




ABAP code using 7.40 inline data declarations to call FM RP_GET_REMAINING_HOLIDAY

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 DATUM FROM SY INTO @DATA(ld_datum).
DATA(ld_datum) = SY-DATUM.
 
 
 
"SELECT single PERNR FROM PERNR INTO @DATA(ld_pernr).
 
 
 
"SELECT single URLJJ FROM P0005 INTO @DATA(ld_urljj).
 
 


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!