SAP HR_RU_AV_REL_QUART_4 Function Module for Relevant periods for calculating quarter bonus for vacation
HR_RU_AV_REL_QUART_4 is a standard hr ru av rel quart 4 SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Relevant periods for calculating quarter bonus for vacation processing and below is the pattern details for this FM, 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 ru av rel quart 4 FM, simply by entering the name HR_RU_AV_REL_QUART_4 into the relevant SAP transaction such as SE37 or SE38.
Function Group: HRPAYRU_PAYROLL_AVERAGES
Program Name: SAPLHRPAYRU_PAYROLL_AVERAGES
Main Program: SAPLHRPAYRU_PAYROLL_AVERAGES
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function HR_RU_AV_REL_QUART_4 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_RU_AV_REL_QUART_4'"Relevant periods for calculating quarter bonus for vacation.
EXPORTING
AV_PERIOD_BEGDA = "
AV_PERIOD_ENDDA = "
I51AV_A = "
I51AV_R = "
APER = "
EMPLOYEE_NUMBER = "
TABLES
RESULT_REL_PAYR = "
RESULTS = "
DATUMSANGABE = "
P0000 = "
P0001 = "
EXCEPTIONS
ERROR = 1
IMPORTING Parameters details for HR_RU_AV_REL_QUART_4
AV_PERIOD_BEGDA -
Data type: SY-DATUMOptional: No
Call by Reference: Yes
AV_PERIOD_ENDDA -
Data type: SY-DATUMOptional: No
Call by Reference: Yes
I51AV_A -
Data type: T51AV_AOptional: No
Call by Reference: Yes
I51AV_R -
Data type: T51AV_ROptional: No
Call by Reference: Yes
APER -
Data type: PC2APEROptional: No
Call by Reference: Yes
EMPLOYEE_NUMBER -
Data type: PERNR-PERNROptional: No
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for HR_RU_AV_REL_QUART_4
RESULT_REL_PAYR -
Data type: HRPY_AV_REL_PAYROptional: No
Call by Reference: No ( called with pass by value option)
RESULTS -
Data type: HRPAY99_TAB_OF_RESULTSOptional: No
Call by Reference: No ( called with pass by value option)
DATUMSANGABE -
Data type: PC2DATESOptional: No
Call by Reference: No ( called with pass by value option)
P0000 -
Data type: P0000Optional: No
Call by Reference: No ( called with pass by value option)
P0001 -
Data type: P0001Optional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
ERROR -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for HR_RU_AV_REL_QUART_4 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_error | TYPE STRING, " | |||
| lv_av_period_begda | TYPE SY-DATUM, " | |||
| lt_result_rel_payr | TYPE STANDARD TABLE OF HRPY_AV_REL_PAYR, " | |||
| lt_results | TYPE STANDARD TABLE OF HRPAY99_TAB_OF_RESULTS, " | |||
| lv_av_period_endda | TYPE SY-DATUM, " | |||
| lv_i51av_a | TYPE T51AV_A, " | |||
| lt_datumsangabe | TYPE STANDARD TABLE OF PC2DATES, " | |||
| lt_p0000 | TYPE STANDARD TABLE OF P0000, " | |||
| lv_i51av_r | TYPE T51AV_R, " | |||
| lv_aper | TYPE PC2APER, " | |||
| lt_p0001 | TYPE STANDARD TABLE OF P0001, " | |||
| lv_employee_number | TYPE PERNR-PERNR. " |
|   CALL FUNCTION 'HR_RU_AV_REL_QUART_4' "Relevant periods for calculating quarter bonus for vacation |
| EXPORTING | ||
| AV_PERIOD_BEGDA | = lv_av_period_begda | |
| AV_PERIOD_ENDDA | = lv_av_period_endda | |
| I51AV_A | = lv_i51av_a | |
| I51AV_R | = lv_i51av_r | |
| APER | = lv_aper | |
| EMPLOYEE_NUMBER | = lv_employee_number | |
| TABLES | ||
| RESULT_REL_PAYR | = lt_result_rel_payr | |
| RESULTS | = lt_results | |
| DATUMSANGABE | = lt_datumsangabe | |
| P0000 | = lt_p0000 | |
| P0001 | = lt_p0001 | |
| EXCEPTIONS | ||
| ERROR = 1 | ||
| . " HR_RU_AV_REL_QUART_4 | ||
ABAP code using 7.40 inline data declarations to call FM HR_RU_AV_REL_QUART_4
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_av_period_begda). | ||||
| "SELECT single DATUM FROM SY INTO @DATA(ld_av_period_endda). | ||||
| "SELECT single PERNR FROM PERNR INTO @DATA(ld_employee_number). | ||||
Search for further information about these or an SAP related objects