SAP DELETE SOURCE ABAP Statements



Get Example source ABAP code based on a different SAP table
  


• TABLE DELETE dbtab

DELETE dbtab, source
Short Reference

ABAP_SYNTAX
... ${@wa$|@( expr )$}
$| ${TABLE @itab$|@( expr )$} ...


ABAP_ALTERNATIVES:
1 ... @wa$|@( expr )
2 ... TABLE @itab$|@( expr )

What does it do?
In the variant DELETE target FROM of the statement DELETE, a non-table-like data object can be specified after FROM, or an internal table after TABLE can be specified as a host variable or host expression. The content of the data objects determines which rows are deleted. Like every host variable, the name of the work area or internal table must be prefixed by the escape character @.



Latest notes:

NON_V5_HINTS
Host variables without the escape character @ are obsolete. The escape character @ must be specified in the strict modes of the syntax check from ABAP_RELEASE ABAP_740_SP05 .
ABAP_HINT_END

ABAP Alternative 1 ... @wa$|@( expr )

What does it do?
If a non-table-like work area is specified as a host variable @wa or host expression @( expr ), a row is searched in the DDIC database table whose primary key content is the same as that of the corresponding initial part of the work area. The content of the work area is not converted and is interpreted according to the structure of the DDIC database table or DDIC view. This row is deleted. The work area must meet the prerequisites for use in AB-SQL statements.
If there is no row in the database with the same content as the primary key, no row is deleted and sy-subrc is set to 4.