Get Example source ABAP code based on a different SAP table
VERSION 5 IN
Creating Objects and Values This section describes how data objects and instances of classes are created and values constructed. ITOC
Creating Objects Creating an object or data object is equivalent to the dynamic creation of an instance of a data type or a class. While instances of classes can only be created as described in this section, instances of data types, that is data objects, declared using the statement DATA>>, or related statements such as CONSTANTS>>, are created automatically as named data objects when their context> is loaded into the ABAP_ISESS . Data objects only need to be created dynamically if the data type is only known when the program is executed, or if large amounts of memory are only to be used for short periods of time. Dynamically created objects can only be addressed using reference variables and are deleted from the ABAP_ISESS by the Garbage Collector> if they are no longer referenced. Objects can be created using one of the following:
CREATE DATA>>
CREATE OBJECT>>
The instance operator> NEW>> for creating objects in general expression positions> and functional operand positions>
The addition NEW>> in the INTO > clause of AB_SQL for the implicit creation of data objects as target areas. Data objects and objects are created in the ABAP_ISESS > of the current program by default, and only programs in the same ABAP_ISESS can access them. BEGIN_SECTION VERSION 5 OUT The following, however, can also be created: