SAP TR_CORRECT_REQUEST_TARGETS Function Module for









TR_CORRECT_REQUEST_TARGETS is a standard tr correct request targets SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used to perform a specific ABAP function and below is the pattern details, 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 tr correct request targets FM, simply by entering the name TR_CORRECT_REQUEST_TARGETS into the relevant SAP transaction such as SE37 or SE38.

Function Group: SCTS_ANALYZE_REQUESTS
Program Name: SAPLSCTS_ANALYZE_REQUESTS
Main Program:
Appliation area: S
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:



Function TR_CORRECT_REQUEST_TARGETS 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 'TR_CORRECT_REQUEST_TARGETS'"
EXPORTING
* IT_REQUEST_NUMBERS = "
* IV_ALL_CUSTS_FOLLOW_STDLAYER = ' ' "
* IS_OLDSTDLAYER = "
* IT_OLDSTDLAYER_PER_CLIENT = "
* IT_OLDCONSOLIDATION_PATHS = "
* IV_CHECK_ONLY = 'X' "
* IV_EXIT_IF_NO_TARGETS_CHANGED = ' ' "

IMPORTING
ET_NOCHANGE_NECESSARY_REQUESTS = "
ET_CHANGED_REQUESTS = "
ET_UNCHANGEABLE_REQUESTS = "
EV_UPDATE_OR_ERRORS_HAPPENED = "
ET_LOCKED_REQUESTS = "
ET_LOG = "

EXCEPTIONS
CTS_INITIALIZATION_FAILURE = 1 INVALID_INPUT = 2
.



IMPORTING Parameters details for TR_CORRECT_REQUEST_TARGETS

IT_REQUEST_NUMBERS -

Data type: TRKORRS
Optional: Yes
Call by Reference: Yes

IV_ALL_CUSTS_FOLLOW_STDLAYER -

Data type: TRBOOLEAN
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

IS_OLDSTDLAYER -

Data type: TCESYST
Optional: Yes
Call by Reference: No ( called with pass by value option)

IT_OLDSTDLAYER_PER_CLIENT -

Data type: TCECLILY_TAB
Optional: Yes
Call by Reference: No ( called with pass by value option)

IT_OLDCONSOLIDATION_PATHS -

Data type: TCERELE_TAB
Optional: Yes
Call by Reference: No ( called with pass by value option)

IV_CHECK_ONLY -

Data type: TRBOOLEAN
Default: 'X'
Optional: Yes
Call by Reference: No ( called with pass by value option)

IV_EXIT_IF_NO_TARGETS_CHANGED -

Data type: TRBOOLEAN
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXPORTING Parameters details for TR_CORRECT_REQUEST_TARGETS

ET_NOCHANGE_NECESSARY_REQUESTS -

Data type: TRREQ_TARS_TAB
Optional: No
Call by Reference: Yes

ET_CHANGED_REQUESTS -

Data type: TRREQ_TARS_TAB
Optional: No
Call by Reference: Yes

ET_UNCHANGEABLE_REQUESTS -

Data type: TRREQ_ERRS_TAB
Optional: No
Call by Reference: Yes

EV_UPDATE_OR_ERRORS_HAPPENED -

Data type: TRBOOLEAN
Optional: No
Call by Reference: No ( called with pass by value option)

ET_LOCKED_REQUESTS -

Data type: TRKORRS
Optional: No
Call by Reference: Yes

ET_LOG -

Data type: SPROT_U_TAB
Optional: No
Call by Reference: Yes

EXCEPTIONS details

CTS_INITIALIZATION_FAILURE -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

INVALID_INPUT -

Data type:
Optional: No
Call by Reference: No ( called with pass by value option)

Copy and paste ABAP code example for TR_CORRECT_REQUEST_TARGETS 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_it_request_numbers  TYPE TRKORRS, "   
lv_cts_initialization_failure  TYPE TRKORRS, "   
lv_et_nochange_necessary_requests  TYPE TRREQ_TARS_TAB, "   
lv_invalid_input  TYPE TRREQ_TARS_TAB, "   
lv_et_changed_requests  TYPE TRREQ_TARS_TAB, "   
lv_iv_all_custs_follow_stdlayer  TYPE TRBOOLEAN, "   SPACE
lv_is_oldstdlayer  TYPE TCESYST, "   
lv_et_unchangeable_requests  TYPE TRREQ_ERRS_TAB, "   
lv_it_oldstdlayer_per_client  TYPE TCECLILY_TAB, "   
lv_ev_update_or_errors_happened  TYPE TRBOOLEAN, "   
lv_et_locked_requests  TYPE TRKORRS, "   
lv_it_oldconsolidation_paths  TYPE TCERELE_TAB, "   
lv_et_log  TYPE SPROT_U_TAB, "   
lv_iv_check_only  TYPE TRBOOLEAN, "   'X'
lv_iv_exit_if_no_targets_changed  TYPE TRBOOLEAN. "   SPACE

  CALL FUNCTION 'TR_CORRECT_REQUEST_TARGETS'  "
    EXPORTING
         IT_REQUEST_NUMBERS = lv_it_request_numbers
         IV_ALL_CUSTS_FOLLOW_STDLAYER = lv_iv_all_custs_follow_stdlayer
         IS_OLDSTDLAYER = lv_is_oldstdlayer
         IT_OLDSTDLAYER_PER_CLIENT = lv_it_oldstdlayer_per_client
         IT_OLDCONSOLIDATION_PATHS = lv_it_oldconsolidation_paths
         IV_CHECK_ONLY = lv_iv_check_only
         IV_EXIT_IF_NO_TARGETS_CHANGED = lv_iv_exit_if_no_targets_changed
    IMPORTING
         ET_NOCHANGE_NECESSARY_REQUESTS = lv_et_nochange_necessary_requests
         ET_CHANGED_REQUESTS = lv_et_changed_requests
         ET_UNCHANGEABLE_REQUESTS = lv_et_unchangeable_requests
         EV_UPDATE_OR_ERRORS_HAPPENED = lv_ev_update_or_errors_happened
         ET_LOCKED_REQUESTS = lv_et_locked_requests
         ET_LOG = lv_et_log
    EXCEPTIONS
        CTS_INITIALIZATION_FAILURE = 1
        INVALID_INPUT = 2
. " TR_CORRECT_REQUEST_TARGETS




ABAP code using 7.40 inline data declarations to call FM TR_CORRECT_REQUEST_TARGETS

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_iv_all_custs_follow_stdlayer) = ' '.
 
 
 
 
 
 
 
 
DATA(ld_iv_check_only) = 'X'.
 
DATA(ld_iv_exit_if_no_targets_changed) = ' '.
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!