SAP Function Modules

RSAR_TRANSTRUCTURE_SAVE SAP Function module - Save transfer rules in any object version







RSAR_TRANSTRUCTURE_SAVE 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 RSAR_TRANSTRUCTURE_SAVE into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: RSAC
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM RSAR_TRANSTRUCTURE_SAVE - RSAR TRANSTRUCTURE SAVE





CALL FUNCTION 'RSAR_TRANSTRUCTURE_SAVE' "Save transfer rules in any object version
  EXPORTING
    i_object =                  " rsa_object    Name of the object (from the OLTP source from 2.0A!)
    i_objtype =                 " rsa_istype    Object Type
*   i_owner =                   " rs_owner
    i_logsys =                  " rsa_logsys    Source System
    i_t_tsfield =               " rsarc_t_rsstsfield  Transfer structure fields
    i_t_tsmapping =             " rsarc_t_rsstsmapping  Transfer rules
    i_objvers =                 " rs_objvers    Object version (active / modified)
*   i_t_delete_rout =           " rsarc_t_convr_iobj
*   i_t_delete_formula =        " rsarc_t_formula_iobj  Table of Formulas for an InfoObject
*   i_percentage = 0            "               Messages percentage of initial value
*   i_without_log = RS_C_FALSE  " rs_bool       No own protocol, open it
*   i_without_transport = RS_C_FALSE  " rs_bool  No transports (after import method)
*   i_segment_id =              " rssegid       Segment ID
  CHANGING
    c_transtru_name =           " rsa_transtru  Name of the transfer structure
*   c_s_is_admin =              " rsarc_s_isoltp_admin  Header data for screen display
  EXCEPTIONS
    NO_ENTRIES_IN_FIELDTABLE = 1  "             Field Table was empty
    WRONG_OBJECTTYPE = 2        "               Object type is unknown
    OBJECT_UNKNOWN = 3          "               Object is unknown, event. wrong type of object
    NO_ACTIVE_COMSTRUCTURE = 4  "               Communication structure is not active / available
    UNKNOWN_LOGSYS = 5          "               Logical System (OLTP) is Unknown
    OBJECT_LOCKED = 6           "               InfoSource, logical system in use
    INCONSISTENCY = 7           "
    TRANSPORT_FAILURE = 8       "               Error during call to transport management
    FORMULA_SAVE = 9            "               Failed to save the formulas
    .  "  RSAR_TRANSTRUCTURE_SAVE

ABAP code example for Function Module RSAR_TRANSTRUCTURE_SAVE





The ABAP code below is a full code listing to execute function module RSAR_TRANSTRUCTURE_SAVE 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_c_transtru_name) = 'Check type of data required'.
DATA(ld_c_s_is_admin) = 'Check type of data required'.
DATA(ld_i_object) = 'Check type of data required'.
DATA(ld_i_objtype) = 'Check type of data required'.
DATA(ld_i_owner) = 'Check type of data required'.
DATA(ld_i_logsys) = 'Check type of data required'.
DATA(ld_i_t_tsfield) = 'Check type of data required'.
DATA(ld_i_t_tsmapping) = 'Check type of data required'.
DATA(ld_i_objvers) = 'Check type of data required'.
DATA(ld_i_t_delete_rout) = 'Check type of data required'.
DATA(ld_i_t_delete_formula) = 'Check type of data required'.
DATA(ld_i_percentage) = 'some text here'.
DATA(ld_i_without_log) = 'Check type of data required'.
DATA(ld_i_without_transport) = 'Check type of data required'.
DATA(ld_i_segment_id) = 'Check type of data required'. . CALL FUNCTION 'RSAR_TRANSTRUCTURE_SAVE' EXPORTING i_object = ld_i_object i_objtype = ld_i_objtype * i_owner = ld_i_owner i_logsys = ld_i_logsys i_t_tsfield = ld_i_t_tsfield i_t_tsmapping = ld_i_t_tsmapping i_objvers = ld_i_objvers * i_t_delete_rout = ld_i_t_delete_rout * i_t_delete_formula = ld_i_t_delete_formula * i_percentage = ld_i_percentage * i_without_log = ld_i_without_log * i_without_transport = ld_i_without_transport * i_segment_id = ld_i_segment_id CHANGING c_transtru_name = ld_c_transtru_name * c_s_is_admin = ld_c_s_is_admin EXCEPTIONS NO_ENTRIES_IN_FIELDTABLE = 1 WRONG_OBJECTTYPE = 2 OBJECT_UNKNOWN = 3 NO_ACTIVE_COMSTRUCTURE = 4 UNKNOWN_LOGSYS = 5 OBJECT_LOCKED = 6 INCONSISTENCY = 7 TRANSPORT_FAILURE = 8 FORMULA_SAVE = 9 . " RSAR_TRANSTRUCTURE_SAVE
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 ELSEIF SY-SUBRC EQ 9. "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_c_transtru_name  TYPE RSA_TRANSTRU ,
ld_i_object  TYPE RSA_OBJECT ,
ld_c_s_is_admin  TYPE RSARC_S_ISOLTP_ADMIN ,
ld_i_objtype  TYPE RSA_ISTYPE ,
ld_i_owner  TYPE RS_OWNER ,
ld_i_logsys  TYPE RSA_LOGSYS ,
ld_i_t_tsfield  TYPE RSARC_T_RSSTSFIELD ,
ld_i_t_tsmapping  TYPE RSARC_T_RSSTSMAPPING ,
ld_i_objvers  TYPE RS_OBJVERS ,
ld_i_t_delete_rout  TYPE RSARC_T_CONVR_IOBJ ,
ld_i_t_delete_formula  TYPE RSARC_T_FORMULA_IOBJ ,
ld_i_percentage  TYPE STRING ,
ld_i_without_log  TYPE RS_BOOL ,
ld_i_without_transport  TYPE RS_BOOL ,
ld_i_segment_id  TYPE RSSEGID .

ld_c_transtru_name = 'Check type of data required'.
ld_i_object = 'Check type of data required'.
ld_c_s_is_admin = 'Check type of data required'.
ld_i_objtype = 'Check type of data required'.
ld_i_owner = 'Check type of data required'.
ld_i_logsys = 'Check type of data required'.
ld_i_t_tsfield = 'Check type of data required'.
ld_i_t_tsmapping = 'Check type of data required'.
ld_i_objvers = 'Check type of data required'.
ld_i_t_delete_rout = 'Check type of data required'.
ld_i_t_delete_formula = 'Check type of data required'.
ld_i_percentage = 'some text here'.
ld_i_without_log = 'Check type of data required'.
ld_i_without_transport = 'Check type of data required'.
ld_i_segment_id = '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 RSAR_TRANSTRUCTURE_SAVE or its description.