SAP RH_TEXT_GET_P0186 Function Module for Text reading routine for I0186
RH_TEXT_GET_P0186 is a standard rh text get p0186 SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Text reading routine for I0186 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 rh text get p0186 FM, simply by entering the name RH_TEXT_GET_P0186 into the relevant SAP transaction such as SE37 or SE38.
Function Group: HRTEXTSG0
Program Name: SAPLHRTEXTSG0
Main Program:
Appliation area: P
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function RH_TEXT_GET_P0186 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 'RH_TEXT_GET_P0186'"Text reading routine for I0186.
EXPORTING
TABNAME = "
* MOLGA = "
* VAR_FIELD = "
FIELDNAME = "
MODE = "
* RECORD = "
* LANGU = SY-LANGU "
* BEGDAT = SY-DATUM "
* ENDDAT = SY-DATUM "
* TCLAS = "
* INFTY_0001 = "
IMPORTING
INFO_TAB = "
TEXT_TAB = "
IMPORTING Parameters details for RH_TEXT_GET_P0186
TABNAME -
Data type: DFIES-TABNAMEOptional: No
Call by Reference: No ( called with pass by value option)
MOLGA -
Data type: T001P-MOLGAOptional: Yes
Call by Reference: No ( called with pass by value option)
VAR_FIELD -
Data type:Optional: Yes
Call by Reference: No ( called with pass by value option)
FIELDNAME -
Data type: DFIES-FIELDNAMEOptional: No
Call by Reference: No ( called with pass by value option)
MODE -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
RECORD -
Data type:Optional: Yes
Call by Reference: No ( called with pass by value option)
LANGU -
Data type: SY-LANGUDefault: SY-LANGU
Optional: Yes
Call by Reference: No ( called with pass by value option)
BEGDAT -
Data type: SY-DATUMDefault: SY-DATUM
Optional: Yes
Call by Reference: No ( called with pass by value option)
ENDDAT -
Data type: SY-DATUMDefault: SY-DATUM
Optional: Yes
Call by Reference: No ( called with pass by value option)
TCLAS -
Data type: T582B-TCLASOptional: Yes
Call by Reference: No ( called with pass by value option)
INFTY_0001 -
Data type: P0001Optional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for RH_TEXT_GET_P0186
INFO_TAB -
Data type: RHTEXT_INFOTABOptional: No
Call by Reference: No ( called with pass by value option)
TEXT_TAB -
Data type: RHTEXT_TABOptional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for RH_TEXT_GET_P0186 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_tabname | TYPE DFIES-TABNAME, " | |||
| lv_info_tab | TYPE RHTEXT_INFOTAB, " | |||
| lv_molga | TYPE T001P-MOLGA, " | |||
| lv_var_field | TYPE T001P, " | |||
| lv_text_tab | TYPE RHTEXT_TAB, " | |||
| lv_fieldname | TYPE DFIES-FIELDNAME, " | |||
| lv_mode | TYPE DFIES, " | |||
| lv_record | TYPE DFIES, " | |||
| lv_langu | TYPE SY-LANGU, " SY-LANGU | |||
| lv_begdat | TYPE SY-DATUM, " SY-DATUM | |||
| lv_enddat | TYPE SY-DATUM, " SY-DATUM | |||
| lv_tclas | TYPE T582B-TCLAS, " | |||
| lv_infty_0001 | TYPE P0001. " |
|   CALL FUNCTION 'RH_TEXT_GET_P0186' "Text reading routine for I0186 |
| EXPORTING | ||
| TABNAME | = lv_tabname | |
| MOLGA | = lv_molga | |
| VAR_FIELD | = lv_var_field | |
| FIELDNAME | = lv_fieldname | |
| MODE | = lv_mode | |
| RECORD | = lv_record | |
| LANGU | = lv_langu | |
| BEGDAT | = lv_begdat | |
| ENDDAT | = lv_enddat | |
| TCLAS | = lv_tclas | |
| INFTY_0001 | = lv_infty_0001 | |
| IMPORTING | ||
| INFO_TAB | = lv_info_tab | |
| TEXT_TAB | = lv_text_tab | |
| . " RH_TEXT_GET_P0186 | ||
ABAP code using 7.40 inline data declarations to call FM RH_TEXT_GET_P0186
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 TABNAME FROM DFIES INTO @DATA(ld_tabname). | ||||
| "SELECT single MOLGA FROM T001P INTO @DATA(ld_molga). | ||||
| "SELECT single FIELDNAME FROM DFIES INTO @DATA(ld_fieldname). | ||||
| "SELECT single LANGU FROM SY INTO @DATA(ld_langu). | ||||
| DATA(ld_langu) | = SY-LANGU. | |||
| "SELECT single DATUM FROM SY INTO @DATA(ld_begdat). | ||||
| DATA(ld_begdat) | = SY-DATUM. | |||
| "SELECT single DATUM FROM SY INTO @DATA(ld_enddat). | ||||
| DATA(ld_enddat) | = SY-DATUM. | |||
| "SELECT single TCLAS FROM T582B INTO @DATA(ld_tclas). | ||||
Search for further information about these or an SAP related objects