Ansicht
Dokumentation

F4UT_POST_SELECTION_PROCESSING - Helper Module for Post Selection from RECORD_TAB

F4UT_POST_SELECTION_PROCESSING - Helper Module for Post Selection from RECORD_TAB

Addresses (Business Address Services)   PERFORM Short Reference  
This documentation is copyright by SAP AG.
SAP E-Book

Functionality

In some search help exits, some lines are removed from the selected hitlist before being display, for example due to an authorization check. This causes the problem that the number of hits no longer matches the number specified by the user. More specifically, if all values need to filtered out of the initial selected values (usually 500), no hitlist is displayed. This is despite the fact that there could be hits if all (or very many) values are selected at the start.

This function module can be used to add to the selected until the specified number of hits is reached, despite any filtered lines.

When the function module is called, the selection is made package by package (using an open database cursor) and passed to the search help exit each time until the required number of hits is reached. For each selected package, the search help exit is called with the step 'POSTSEL' (CALLCONTROL-STEP). This step is not usually part of the regular F4 action. It is available only if the function module F4UT_POST_SELECTION_PROCESSING is called first.

The step POSTSEL provides the last selected package in the table RECORD_TAB. In this case, the number of entries in the internal table can, for example, be reduced by an authorization check. The step is called for each new package until the specified maximum number of hits is reached or exceeded or until no more entries can be selected.

Caution: The function module uses the full SELECT step and then switches it to DISP. A search help exit is not called again before the display. If the search help exit needs to be applied again after DISP time, the query IF CALLCONTROL-STEP = 'DISP' should be made after function module is called.

Example

The function module F4UT_POST_SELECTION_EXAMPLE shows an example of an authorization check.

Notes

This module cannot be used if a help view is used as a selection method.

A database cursor is open during the selection, which means that no commands can be made at POSTSEL time that interrupt a database selection. These commands include COMMIT, ROLLBACK, CALL TRANSACTION, CALL SCREEN, SUBMIT, and MESSAGE. The search help exits can also produce runtime errors when being debugged, since the debugger sometimes force COMMITs.

The package size is adjusted dynamically to the ratio of selected values to filtered values. If the ratio is constant, the second call of the POSTSEL step is given the exact number of lines that remain after the specified number of hits is filtered.

Further information





Parameters

CALLCONTROL
PROVIDE_ALL_RECORDS
RECORD_TAB
SHLP
SHLP_TAB

Exceptions

Function Group

SF4U

rdisp/max_wprun_time - Maximum work process run time   ABAP Short Reference  
This documentation is copyright by SAP AG.

Length: 3002 Date: 20240523 Time: 065145     sap01-206 ( 72 ms )