SAP RSAR_TREE_INIT Function Module for Tree initialization









RSAR_TREE_INIT is a standard rsar tree init SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Tree initialization 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 rsar tree init FM, simply by entering the name RSAR_TREE_INIT into the relevant SAP transaction such as SE37 or SE38.

Function Group: RSATREE
Program Name: SAPLRSATREE
Main Program: SAPLRSATREE
Appliation area: B
Release date: 24-Oct-1997
Mode(Normal, Remote etc): Normal Function Module
Update:



Function RSAR_TREE_INIT 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 'RSAR_TREE_INIT'"Tree initialization
IMPORTING
NODE_ID_IS = "
TREE_ID_IC = "
TREE_ID_IO = "
TREE_ID_IPG = "
TREE_ID_ODS = "
TREE_ID_DS = "
NODE_ID_LG = "
NODE_ID_IC = "
NODE_ID_IO = "
NODE_ID_IPG = "
NODE_ID_ODS = "
NODE_ID_DS = "
TREE_ID_IS = "
TREE_ID_LG = "

EXCEPTIONS
LOCKED = 1
.



EXPORTING Parameters details for RSAR_TREE_INIT

NODE_ID_IS -

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

TREE_ID_IC -

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

TREE_ID_IO -

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

TREE_ID_IPG -

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

TREE_ID_ODS -

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

TREE_ID_DS -

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

NODE_ID_LG -

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

NODE_ID_IC -

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

NODE_ID_IO -

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

NODE_ID_IPG -

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

NODE_ID_ODS -

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

NODE_ID_DS -

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

TREE_ID_IS -

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

TREE_ID_LG -

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

EXCEPTIONS details

LOCKED -

Data type:
Optional: No
Call by Reference: Yes

Copy and paste ABAP code example for RSAR_TREE_INIT 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_locked  TYPE STRING, "   
lv_node_id_is  TYPE RSATD_NODE-ID, "   
lv_tree_id_ic  TYPE RSATD_TREE-ID, "   
lv_tree_id_io  TYPE RSATD_TREE-ID, "   
lv_tree_id_ipg  TYPE RSATD_TREE-ID, "   
lv_tree_id_ods  TYPE RSATD_TREE-ID, "   
lv_tree_id_ds  TYPE RSATD_TREE-ID, "   
lv_node_id_lg  TYPE RSATD_NODE-ID, "   
lv_node_id_ic  TYPE RSATD_NODE-ID, "   
lv_node_id_io  TYPE RSATD_NODE-ID, "   
lv_node_id_ipg  TYPE RSATD_NODE-ID, "   
lv_node_id_ods  TYPE RSATD_NODE-ID, "   
lv_node_id_ds  TYPE RSATD_NODE-ID, "   
lv_tree_id_is  TYPE RSATD_TREE-ID, "   
lv_tree_id_lg  TYPE RSATD_TREE-ID. "   

  CALL FUNCTION 'RSAR_TREE_INIT'  "Tree initialization
    IMPORTING
         NODE_ID_IS = lv_node_id_is
         TREE_ID_IC = lv_tree_id_ic
         TREE_ID_IO = lv_tree_id_io
         TREE_ID_IPG = lv_tree_id_ipg
         TREE_ID_ODS = lv_tree_id_ods
         TREE_ID_DS = lv_tree_id_ds
         NODE_ID_LG = lv_node_id_lg
         NODE_ID_IC = lv_node_id_ic
         NODE_ID_IO = lv_node_id_io
         NODE_ID_IPG = lv_node_id_ipg
         NODE_ID_ODS = lv_node_id_ods
         NODE_ID_DS = lv_node_id_ds
         TREE_ID_IS = lv_tree_id_is
         TREE_ID_LG = lv_tree_id_lg
    EXCEPTIONS
        LOCKED = 1
. " RSAR_TREE_INIT




ABAP code using 7.40 inline data declarations to call FM RSAR_TREE_INIT

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 ID FROM RSATD_NODE INTO @DATA(ld_node_id_is).
 
"SELECT single ID FROM RSATD_TREE INTO @DATA(ld_tree_id_ic).
 
"SELECT single ID FROM RSATD_TREE INTO @DATA(ld_tree_id_io).
 
"SELECT single ID FROM RSATD_TREE INTO @DATA(ld_tree_id_ipg).
 
"SELECT single ID FROM RSATD_TREE INTO @DATA(ld_tree_id_ods).
 
"SELECT single ID FROM RSATD_TREE INTO @DATA(ld_tree_id_ds).
 
"SELECT single ID FROM RSATD_NODE INTO @DATA(ld_node_id_lg).
 
"SELECT single ID FROM RSATD_NODE INTO @DATA(ld_node_id_ic).
 
"SELECT single ID FROM RSATD_NODE INTO @DATA(ld_node_id_io).
 
"SELECT single ID FROM RSATD_NODE INTO @DATA(ld_node_id_ipg).
 
"SELECT single ID FROM RSATD_NODE INTO @DATA(ld_node_id_ods).
 
"SELECT single ID FROM RSATD_NODE INTO @DATA(ld_node_id_ds).
 
"SELECT single ID FROM RSATD_TREE INTO @DATA(ld_tree_id_is).
 
"SELECT single ID FROM RSATD_TREE INTO @DATA(ld_tree_id_lg).
 


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!