SAP GEN_HELPVIEW_SELECTION Function Module for Generates selection routines for help views
GEN_HELPVIEW_SELECTION is a standard gen helpview selection SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Generates selection routines for help views 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 gen helpview selection FM, simply by entering the name GEN_HELPVIEW_SELECTION into the relevant SAP transaction such as SE37 or SE38.
Function Group: SDM2
Program Name: SAPLSDM2
Main Program:
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function GEN_HELPVIEW_SELECTION 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 'GEN_HELPVIEW_SELECTION'"Generates selection routines for help views.
EXPORTING
DD25V_WA = "
* GEN_FORCED = ' ' "
* TEST_ONLY = ' ' "
* PRID = 0 "
IMPORTING
PROGNAME = "Internal table with tuples for bui
TABLES
DD28V_TAB = "Selection Conditions
DD27P_TAB = "View fields
DD26V_TAB = "
EXCEPTIONS
PROG_WAS_MODIFIED = 1 REP_IS_INCONSISTENT = 2 REP_NOT_FOUND = 3 VIEW_IS_INCONSISTENT = 4 VIEW_NOT_FOUND = 5
IMPORTING Parameters details for GEN_HELPVIEW_SELECTION
DD25V_WA -
Data type: DD25VOptional: No
Call by Reference: No ( called with pass by value option)
GEN_FORCED -
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
TEST_ONLY -
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
PRID -
Data type: SY-TABIXOptional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for GEN_HELPVIEW_SELECTION
PROGNAME - Internal table with tuples for bui
Data type: TRDIR-NAMEOptional: No
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for GEN_HELPVIEW_SELECTION
DD28V_TAB - Selection Conditions
Data type: DD28VOptional: No
Call by Reference: No ( called with pass by value option)
DD27P_TAB - View fields
Data type: DD27POptional: No
Call by Reference: No ( called with pass by value option)
DD26V_TAB -
Data type: DD26VOptional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
PROG_WAS_MODIFIED -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
REP_IS_INCONSISTENT - Internal table with tuples for bui
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
REP_NOT_FOUND - Internal table with tuples for bui
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
VIEW_IS_INCONSISTENT - Internal table with tuples for bui
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
VIEW_NOT_FOUND - Internal table with tuples for bui
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for GEN_HELPVIEW_SELECTION 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_dd25v_wa | TYPE DD25V, " | |||
| lv_progname | TYPE TRDIR-NAME, " | |||
| lt_dd28v_tab | TYPE STANDARD TABLE OF DD28V, " | |||
| lv_prog_was_modified | TYPE DD28V, " | |||
| lt_dd27p_tab | TYPE STANDARD TABLE OF DD27P, " | |||
| lv_gen_forced | TYPE DD27P, " SPACE | |||
| lv_rep_is_inconsistent | TYPE DD27P, " | |||
| lt_dd26v_tab | TYPE STANDARD TABLE OF DD26V, " | |||
| lv_test_only | TYPE DD26V, " SPACE | |||
| lv_rep_not_found | TYPE DD26V, " | |||
| lv_prid | TYPE SY-TABIX, " 0 | |||
| lv_view_is_inconsistent | TYPE SY, " | |||
| lv_view_not_found | TYPE SY. " |
|   CALL FUNCTION 'GEN_HELPVIEW_SELECTION' "Generates selection routines for help views |
| EXPORTING | ||
| DD25V_WA | = lv_dd25v_wa | |
| GEN_FORCED | = lv_gen_forced | |
| TEST_ONLY | = lv_test_only | |
| PRID | = lv_prid | |
| IMPORTING | ||
| PROGNAME | = lv_progname | |
| TABLES | ||
| DD28V_TAB | = lt_dd28v_tab | |
| DD27P_TAB | = lt_dd27p_tab | |
| DD26V_TAB | = lt_dd26v_tab | |
| EXCEPTIONS | ||
| PROG_WAS_MODIFIED = 1 | ||
| REP_IS_INCONSISTENT = 2 | ||
| REP_NOT_FOUND = 3 | ||
| VIEW_IS_INCONSISTENT = 4 | ||
| VIEW_NOT_FOUND = 5 | ||
| . " GEN_HELPVIEW_SELECTION | ||
ABAP code using 7.40 inline data declarations to call FM GEN_HELPVIEW_SELECTION
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 NAME FROM TRDIR INTO @DATA(ld_progname). | ||||
| DATA(ld_gen_forced) | = ' '. | |||
| DATA(ld_test_only) | = ' '. | |||
| "SELECT single TABIX FROM SY INTO @DATA(ld_prid). | ||||
Search for further information about these or an SAP related objects