SAP HR_F4_GET_TABLES Function Module for Define Subtype Tables of Infotype
HR_F4_GET_TABLES is a standard hr f4 get tables SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Define Subtype Tables of Infotype 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 f4 get tables FM, simply by entering the name HR_F4_GET_TABLES into the relevant SAP transaction such as SE37 or SE38.
Function Group: HRPAD00INFTY
Program Name: SAPLHRPAD00INFTY
Main Program: SAPLHRPAD00INFTY
Appliation area:
Release date: 05-Nov-1999
Mode(Normal, Remote etc): Normal Function Module
Update:

Function HR_F4_GET_TABLES 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_F4_GET_TABLES'"Define Subtype Tables of Infotype.
EXPORTING
INFTY = "Infotype
* PERSNR = "Personnel Number
* TCLAS = 'A' "Transaction Class for Data Storage
* BEGDA = SY-DATUM "Date
* ENDDA = SY-DATUM "Date
* LANGU = SY-LANGU "Language Key
* MOLGA = "Country Grouping
IMPORTING
VALUE_TAB = "F4 Help: Table of Values, Entries Cell by Cell
FIELD_TAB = "F4 Help: Hit List Fields
RETFIELD = "Field Name
EXCEPTIONS
INFTY_NOT_FOUND = 1 NO_ENTRIES_FOUND = 2 INFTY_NOT_SUPPORTED = 3 INFTY_HAS_NO_SUBTIES = 4
IMPORTING Parameters details for HR_F4_GET_TABLES
INFTY - Infotype
Data type: INFTYOptional: No
Call by Reference: No ( called with pass by value option)
PERSNR - Personnel Number
Data type: PERNR_DOptional: Yes
Call by Reference: No ( called with pass by value option)
TCLAS - Transaction Class for Data Storage
Data type: TCLASDefault: 'A'
Optional: Yes
Call by Reference: No ( called with pass by value option)
BEGDA - Date
Data type: DATUMDefault: SY-DATUM
Optional: Yes
Call by Reference: No ( called with pass by value option)
ENDDA - Date
Data type: DATUMDefault: SY-DATUM
Optional: Yes
Call by Reference: No ( called with pass by value option)
LANGU - Language Key
Data type: SPRASDefault: SY-LANGU
Optional: Yes
Call by Reference: No ( called with pass by value option)
MOLGA - Country Grouping
Data type: MOLGAOptional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for HR_F4_GET_TABLES
VALUE_TAB - F4 Help: Table of Values, Entries Cell by Cell
Data type: HRVALUE_TABOptional: No
Call by Reference: Yes
FIELD_TAB - F4 Help: Hit List Fields
Data type: HRHELP_FIELDSOptional: No
Call by Reference: Yes
RETFIELD - Field Name
Data type: DFIES-FIELDNAMEOptional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
INFTY_NOT_FOUND -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
NO_ENTRIES_FOUND -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
INFTY_NOT_SUPPORTED -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
INFTY_HAS_NO_SUBTIES -
Data type:Optional: No
Call by Reference: Yes
Copy and paste ABAP code example for HR_F4_GET_TABLES 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_infty | TYPE INFTY, " | |||
| lv_value_tab | TYPE HRVALUE_TAB, " | |||
| lv_infty_not_found | TYPE HRVALUE_TAB, " | |||
| lv_persnr | TYPE PERNR_D, " | |||
| lv_field_tab | TYPE HRHELP_FIELDS, " | |||
| lv_no_entries_found | TYPE HRHELP_FIELDS, " | |||
| lv_tclas | TYPE TCLAS, " 'A' | |||
| lv_retfield | TYPE DFIES-FIELDNAME, " | |||
| lv_infty_not_supported | TYPE DFIES, " | |||
| lv_begda | TYPE DATUM, " SY-DATUM | |||
| lv_infty_has_no_subties | TYPE DATUM, " | |||
| lv_endda | TYPE DATUM, " SY-DATUM | |||
| lv_langu | TYPE SPRAS, " SY-LANGU | |||
| lv_molga | TYPE MOLGA. " |
|   CALL FUNCTION 'HR_F4_GET_TABLES' "Define Subtype Tables of Infotype |
| EXPORTING | ||
| INFTY | = lv_infty | |
| PERSNR | = lv_persnr | |
| TCLAS | = lv_tclas | |
| BEGDA | = lv_begda | |
| ENDDA | = lv_endda | |
| LANGU | = lv_langu | |
| MOLGA | = lv_molga | |
| IMPORTING | ||
| VALUE_TAB | = lv_value_tab | |
| FIELD_TAB | = lv_field_tab | |
| RETFIELD | = lv_retfield | |
| EXCEPTIONS | ||
| INFTY_NOT_FOUND = 1 | ||
| NO_ENTRIES_FOUND = 2 | ||
| INFTY_NOT_SUPPORTED = 3 | ||
| INFTY_HAS_NO_SUBTIES = 4 | ||
| . " HR_F4_GET_TABLES | ||
ABAP code using 7.40 inline data declarations to call FM HR_F4_GET_TABLES
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.| DATA(ld_tclas) | = 'A'. | |||
| "SELECT single FIELDNAME FROM DFIES INTO @DATA(ld_retfield). | ||||
| DATA(ld_begda) | = SY-DATUM. | |||
| DATA(ld_endda) | = SY-DATUM. | |||
| DATA(ld_langu) | = SY-LANGU. | |||
Search for further information about these or an SAP related objects