SAP Function Modules

HR_SEN_EVALUATE_DURATION SAP Function module







HR_SEN_EVALUATE_DURATION is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name HR_SEN_EVALUATE_DURATION into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: HRSEN00MODEL_EVALUATION
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM HR_SEN_EVALUATE_DURATION - HR SEN EVALUATE DURATION





CALL FUNCTION 'HR_SEN_EVALUATE_DURATION' "
  EXPORTING
    p_pernr =                   " persno
    p_tspst =                   " tspst
    p_begda =                   " begda
    p_endda =                   " endda
    p_sdate =                   " d
    p_crule =                   " psen_crule
*   p_autho =                   " psen_autho
*   is_tspst_control =          " psen_tspst_control
*   p_proto =                   " psen_proto
  IMPORTING
    p_durat =                   " psen_duration_dec
    et_weight_period =          " hrsen00_weight_period
    et_weight_peak =            " hrsen00_weight_peak_dec
  EXCEPTIONS
    E_MISSING_AUTHORIZATION = 1  "
    E_OTHERS = 2                "
    .  "  HR_SEN_EVALUATE_DURATION

ABAP code example for Function Module HR_SEN_EVALUATE_DURATION





The ABAP code below is a full code listing to execute function module HR_SEN_EVALUATE_DURATION including all data declarations. The code uses 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 original method of declaring data variables up front. 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).

DATA:
ld_p_durat  TYPE PSEN_DURATION_DEC ,
ld_et_weight_period  TYPE HRSEN00_WEIGHT_PERIOD ,
ld_et_weight_peak  TYPE HRSEN00_WEIGHT_PEAK_DEC .

DATA(ld_p_pernr) = 'Check type of data required'.
DATA(ld_p_tspst) = 'Check type of data required'.
DATA(ld_p_begda) = 'Check type of data required'.
DATA(ld_p_endda) = 'Check type of data required'.
DATA(ld_p_sdate) = 'Check type of data required'.
DATA(ld_p_crule) = 'Check type of data required'.
DATA(ld_p_autho) = 'Check type of data required'.
DATA(ld_is_tspst_control) = 'Check type of data required'.
DATA(ld_p_proto) = 'Check type of data required'. . CALL FUNCTION 'HR_SEN_EVALUATE_DURATION' EXPORTING p_pernr = ld_p_pernr p_tspst = ld_p_tspst p_begda = ld_p_begda p_endda = ld_p_endda p_sdate = ld_p_sdate p_crule = ld_p_crule * p_autho = ld_p_autho * is_tspst_control = ld_is_tspst_control * p_proto = ld_p_proto IMPORTING p_durat = ld_p_durat et_weight_period = ld_et_weight_period et_weight_peak = ld_et_weight_peak EXCEPTIONS E_MISSING_AUTHORIZATION = 1 E_OTHERS = 2 . " HR_SEN_EVALUATE_DURATION
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 2. "Exception "Add code for exception here ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_p_durat  TYPE PSEN_DURATION_DEC ,
ld_p_pernr  TYPE PERSNO ,
ld_et_weight_period  TYPE HRSEN00_WEIGHT_PERIOD ,
ld_p_tspst  TYPE TSPST ,
ld_et_weight_peak  TYPE HRSEN00_WEIGHT_PEAK_DEC ,
ld_p_begda  TYPE BEGDA ,
ld_p_endda  TYPE ENDDA ,
ld_p_sdate  TYPE D ,
ld_p_crule  TYPE PSEN_CRULE ,
ld_p_autho  TYPE PSEN_AUTHO ,
ld_is_tspst_control  TYPE PSEN_TSPST_CONTROL ,
ld_p_proto  TYPE PSEN_PROTO .

ld_p_pernr = 'Check type of data required'.
ld_p_tspst = 'Check type of data required'.
ld_p_begda = 'Check type of data required'.
ld_p_endda = 'Check type of data required'.
ld_p_sdate = 'Check type of data required'.
ld_p_crule = 'Check type of data required'.
ld_p_autho = 'Check type of data required'.
ld_is_tspst_control = 'Check type of data required'.
ld_p_proto = 'Check type of data required'.

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name HR_SEN_EVALUATE_DURATION or its description.