SAP Function Modules

RSEC_MODIFY_AUTHORIZATION_API SAP Function module - Updates an Analysis Authorization







RSEC_MODIFY_AUTHORIZATION_API is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name RSEC_MODIFY_AUTHORIZATION_API into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: RSEC_API
Released Date: Not Released
Processing type: Remote-Enabled
remote enabled module settings


Pattern for FM RSEC_MODIFY_AUTHORIZATION_API - RSEC MODIFY AUTHORIZATION API





CALL FUNCTION 'RSEC_MODIFY_AUTHORIZATION_API' "Updates an Analysis Authorization
  EXPORTING
    i_authname =                " rsauth        BW Analysis Authorizations: Name of an Authorization
    i_t_range =                 " rsec_t_range_api  Authorized Values and Ranges for InfoObjects
    i_t_hierarchy =             " rsec_t_hierarchy_api  Authorization on Hierarchies for InfoObjects
    i_short_text =              " rstxt20       Short Description
    i_activate_auth = 'X'       " rs_bool       Boolean
*   i_mid_text =                " rstxtmd       Medium Description
*   i_long_text =               " rstxtlg       Long Description
  IMPORTING
    e_t_messages =              " rs_t_msg      BW: Table with Messages (Application Log)
  EXCEPTIONS
    NO_AUTHORIZATION = 1        "
    FORBIDDEN_SIGNS_IN_NAME = 2  "
    WRONG_NAME = 3              "
    AUTHORIZATION_IS_EMPTY = 4  "
    EMPTY_SHORT_TEXT = 5        "
    NO_CHANGE_AUTH = 6          "
    NO_CREATE_AUTH = 7          "
    AUTH_LOCKED = 8             "
    .  "  RSEC_MODIFY_AUTHORIZATION_API

ABAP code example for Function Module RSEC_MODIFY_AUTHORIZATION_API





The ABAP code below is a full code listing to execute function module RSEC_MODIFY_AUTHORIZATION_API including all data declarations. The code uses 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 original method of declaring data variables up front. 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).

DATA:
ld_e_t_messages  TYPE RS_T_MSG .

DATA(ld_i_authname) = 'Check type of data required'.
DATA(ld_i_t_range) = 'Check type of data required'.
DATA(ld_i_t_hierarchy) = 'Check type of data required'.
DATA(ld_i_short_text) = 'Check type of data required'.
DATA(ld_i_activate_auth) = 'Check type of data required'.
DATA(ld_i_mid_text) = 'Check type of data required'.
DATA(ld_i_long_text) = 'Check type of data required'. . CALL FUNCTION 'RSEC_MODIFY_AUTHORIZATION_API' EXPORTING i_authname = ld_i_authname i_t_range = ld_i_t_range i_t_hierarchy = ld_i_t_hierarchy i_short_text = ld_i_short_text i_activate_auth = ld_i_activate_auth * i_mid_text = ld_i_mid_text * i_long_text = ld_i_long_text IMPORTING e_t_messages = ld_e_t_messages EXCEPTIONS NO_AUTHORIZATION = 1 FORBIDDEN_SIGNS_IN_NAME = 2 WRONG_NAME = 3 AUTHORIZATION_IS_EMPTY = 4 EMPTY_SHORT_TEXT = 5 NO_CHANGE_AUTH = 6 NO_CREATE_AUTH = 7 AUTH_LOCKED = 8 . " RSEC_MODIFY_AUTHORIZATION_API
IF SY-SUBRC EQ 0. "All OK ELSEIF SY-SUBRC EQ 1. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 2. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 3. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 4. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 5. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 6. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 7. "Exception "Add code for exception here ELSEIF SY-SUBRC EQ 8. "Exception "Add code for exception here ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_e_t_messages  TYPE RS_T_MSG ,
ld_i_authname  TYPE RSAUTH ,
ld_i_t_range  TYPE RSEC_T_RANGE_API ,
ld_i_t_hierarchy  TYPE RSEC_T_HIERARCHY_API ,
ld_i_short_text  TYPE RSTXT20 ,
ld_i_activate_auth  TYPE RS_BOOL ,
ld_i_mid_text  TYPE RSTXTMD ,
ld_i_long_text  TYPE RSTXTLG .

ld_i_authname = 'Check type of data required'.
ld_i_t_range = 'Check type of data required'.
ld_i_t_hierarchy = 'Check type of data required'.
ld_i_short_text = 'Check type of data required'.
ld_i_activate_auth = 'Check type of data required'.
ld_i_mid_text = 'Check type of data required'.
ld_i_long_text = 'Check type of data required'.

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name RSEC_MODIFY_AUTHORIZATION_API or its description.