NODES node [TYPE type].
The sole effect of the NODES statement is to copy data from logical databases to executable programs. It defines an interface work area and is allowed only in the global declaration section of executable programs that are linked to a logical database, and in the database program of logical databases. node must be the name of a node of the logical database. NODES declares a table work area node for the respective node. The data type of the table work area is either predefined in the node of the logical database or can be chosen from a list using addition TYPE.
The nodes of the structure of a logical database are maintained in transaction SE36 and can have the following node types:
The NODES (or TABLES) statement of the executable program controls the structure of the standard selection screen of the logical database. Only those input fields are displayed, for whose nodes or hierarchically directly inferior nodes a corresponding NODES (or TABLES) statement appears in the executable program.
The database program is responsible for assigning data to the table work area. For every node of the logical database, there is a subroutine PUT_node in the database program, which uses the PUT statement to signal to the executable program that in the table work area node data is available.
For all tables work areas node specified afterNODES (or TABLES), you can create event blocks for the reporting events GET node [LATE]. The events are triggered by the PUT node or PUT <node> statements in the database program. After such an event, the table work area filled in the database program can be evaluated in the executable program. For nodes of type A, the data is available only within the event blocks. For all other types, the data is available throughout the executable program.
Table areas declared with NODES behave like common data
declared with addition COMMON PART: They are shared by the programs of a
A logical database contains a root node root_node of node type S, to which the data type INT4 is assigned. The top include of the database program then contains the statement:
In addition, the database program contains this subroutine:
DO 10 TIMES.
root_node = sy-index.
If the executable program below is linked to the logical database, it recieves during program execution the numbers from 1 to 10 in the table work area root_node and at the event GET writes them into a list: