Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Identify non-deleted entries

0 Kudos
159

Hi All,

I am using the statement:

DELETE FROM marc WHERE matnr IN lt_matnr_range.

My range table LT_MATNR_RANGE has around 40 entries.

If I get SY-SUBRC = 4, then, is there any way to know which entries of MATNR have not got deleted?

Many thanks in advance,

Best Regards,

Anu

2 REPLIES 2

0 Kudos
123

Hi Anu,

in the example above none of the entries get deleted because it's a database table (partial delete works only with internal tables).

Just check sy-dbcnt, because this field would contain the count of the deleted entries.

Regards

Nicola

amy_king
Active Contributor
0 Kudos
123

Hi Anu,

You shouldn't directly modify standard database tables. Doing so violates your company's service contract with SAP since changes you make to one table aren't propagated to related tables. Try to find a function module or BAPI or use BDC to make the necessary changes.

Cheers,

Amy