SAP EXIT_HARCALC0_003 Function Module for Basis calculation for ART leave









EXIT_HARCALC0_003 is a standard exit harcalc0 003 SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Basis calculation for ART leave 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 exit harcalc0 003 FM, simply by entering the name EXIT_HARCALC0_003 into the relevant SAP transaction such as SE37 or SE38.

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



Function EXIT_HARCALC0_003 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 'EXIT_HARCALC0_003'"Basis calculation for ART leave
EXPORTING
NRO_PERSONAL = "Personnel number
PRIMER_DIA_MES = "Valid from date
ULTIMO_DIA_MES = "Valid to date
APER_PAYTY = "Payroll type
APER_CALCD = "
DIAS_DEL_MES = "
VALOR_MOPRE = "Personnel payroll: Amount
APER_ABKRS = "Payroll area
APER_PAPER = "Payroll period

TABLES
IT = "Payroll result: Result table
INF_0001 = "Personnel master record Infotype 0001 (Organizational assign.)
WPBP = "Payroll result: Work centre/Basic pay
INF_2001 = "Personnel time record Infotype 2001 (Absences)
AB = "Cluster RD/B2: Table AB
ARDIV = "Correction of days according to month divisor
.



IMPORTING Parameters details for EXIT_HARCALC0_003

NRO_PERSONAL - Personnel number

Data type: PA0001-PERNR
Optional: No
Call by Reference: Yes

PRIMER_DIA_MES - Valid from date

Data type: PA2001-BEGDA
Optional: No
Call by Reference: Yes

ULTIMO_DIA_MES - Valid to date

Data type: PA2001-ENDDA
Optional: No
Call by Reference: Yes

APER_PAYTY - Payroll type

Data type: PC261-PAYTY
Optional: No
Call by Reference: Yes

APER_CALCD -

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

DIAS_DEL_MES -

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

VALOR_MOPRE - Personnel payroll: Amount

Data type: PC207-BETRG
Optional: No
Call by Reference: Yes

APER_ABKRS - Payroll area

Data type: P0001-ABKRS
Optional: No
Call by Reference: Yes

APER_PAPER - Payroll period

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

TABLES Parameters details for EXIT_HARCALC0_003

IT - Payroll result: Result table

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

INF_0001 - Personnel master record Infotype 0001 (Organizational assign.)

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

WPBP - Payroll result: Work centre/Basic pay

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

INF_2001 - Personnel time record Infotype 2001 (Absences)

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

AB - Cluster RD/B2: Table AB

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

ARDIV - Correction of days according to month divisor

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

Copy and paste ABAP code example for EXIT_HARCALC0_003 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_it  TYPE STANDARD TABLE OF PC207, "   
lv_nro_personal  TYPE PA0001-PERNR, "   
lt_inf_0001  TYPE STANDARD TABLE OF P0001, "   
lv_primer_dia_mes  TYPE PA2001-BEGDA, "   
lt_wpbp  TYPE STANDARD TABLE OF PC205, "   
lv_ultimo_dia_mes  TYPE PA2001-ENDDA, "   
lt_inf_2001  TYPE STANDARD TABLE OF P2001, "   
lv_aper_payty  TYPE PC261-PAYTY, "   
lt_ab  TYPE STANDARD TABLE OF PC20I, "   
lv_aper_calcd  TYPE C, "   
lt_ardiv  TYPE STANDARD TABLE OF PC2LA, "   
lv_dias_del_mes  TYPE I, "   
lv_valor_mopre  TYPE PC207-BETRG, "   
lv_aper_abkrs  TYPE P0001-ABKRS, "   
lv_aper_paper  TYPE PAPER. "   

  CALL FUNCTION 'EXIT_HARCALC0_003'  "Basis calculation for ART leave
    EXPORTING
         NRO_PERSONAL = lv_nro_personal
         PRIMER_DIA_MES = lv_primer_dia_mes
         ULTIMO_DIA_MES = lv_ultimo_dia_mes
         APER_PAYTY = lv_aper_payty
         APER_CALCD = lv_aper_calcd
         DIAS_DEL_MES = lv_dias_del_mes
         VALOR_MOPRE = lv_valor_mopre
         APER_ABKRS = lv_aper_abkrs
         APER_PAPER = lv_aper_paper
    TABLES
         IT = lt_it
         INF_0001 = lt_inf_0001
         WPBP = lt_wpbp
         INF_2001 = lt_inf_2001
         AB = lt_ab
         ARDIV = lt_ardiv
. " EXIT_HARCALC0_003




ABAP code using 7.40 inline data declarations to call FM EXIT_HARCALC0_003

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 PERNR FROM PA0001 INTO @DATA(ld_nro_personal).
 
 
"SELECT single BEGDA FROM PA2001 INTO @DATA(ld_primer_dia_mes).
 
 
"SELECT single ENDDA FROM PA2001 INTO @DATA(ld_ultimo_dia_mes).
 
 
"SELECT single PAYTY FROM PC261 INTO @DATA(ld_aper_payty).
 
 
 
 
 
"SELECT single BETRG FROM PC207 INTO @DATA(ld_valor_mopre).
 
"SELECT single ABKRS FROM P0001 INTO @DATA(ld_aper_abkrs).
 
 


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!