Get Example source ABAP code based on a different SAP table
ID ADD-TO • ADD ABAP Statement • TO ADD (obsolete)
ADD> Short Reference >
ABAP_SYNTAX_OBS ADD dobj1 TO dobj2.>
What does it do? This statement has the same effect as the statement dobj2 += dobj1.>> that is the same as dobj2 = dobj2 + dobj1.>> The content of dobj1> is added to the content of dobj2> and the result is assigned to dobj2>. The data objects dobj1> and dobj2> must be numeric. Only data objects can be specified, no calls or other expressions. The calculation type> is determined as for an arithmetic expression>.
Latest notes: The statement ADD> has been fully replaced by the calculation assignment> with the operator +=>> in which the operands can also be specified as expressions. NON_V5_HINTS ABAP_HINT_END
Example ABAP Coding
The variable result_old> has the value 10> after the calculation statements. The syntax for the calculation assignment> with the same effect is also shown. ABEXA 00001 ABAP_EXAMPLE_END