Application Development and Automation 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: 
Read only

delete table entries

Former Member
0 Likes
632

hi

i want to delete table entries based on the internal table

can i use for all entires for delete?

if so how?

i dont want to use loop as it takes more time

regards

senthtil

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
606

H!

FOR ALL ENTRIES is not available to DELETE.

You can use the WHERE or the INDEX statements.

DELETE itab WHERE matnr = '123'.

LOOP AT itab2.

DELETE itab INDEX sy-tabix. "delete by itab2's SY-TABIX

ENDLOOP.

Regards

Tamá

4 REPLIES 4
Read only

Former Member
0 Likes
607

H!

FOR ALL ENTRIES is not available to DELETE.

You can use the WHERE or the INDEX statements.

DELETE itab WHERE matnr = '123'.

LOOP AT itab2.

DELETE itab INDEX sy-tabix. "delete by itab2's SY-TABIX

ENDLOOP.

Regards

Tamá

Read only

Former Member
0 Likes
606

Hi Senthil,

do like this

delete <itab> where ....

Reward if it helps,

Satish

Read only

Former Member
0 Likes
606

Hi,

You can use as below :

Delete itab where fieldname = 'some value'.

Above code will delete all the entries from the internal table which satisfies the condition.

Thanks,

Sriram Ponna.

Read only

kostas_tsioubris
Contributor
0 Likes
606

Hi,

you are not making clear if you want to delete the internal table entries or ddic table entries, in case you want to delete internal table entries use one of the above suggestions else use something like this.

delete ddic_table from table itab[].

Kostas