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

How to delete internal table entries with out using loop

Former Member
0 Likes
4,734

Hi all,

My Internal table consists of following fields and entries. I want delete particular set of entries without using loop. For example ITAB is:

BUKRS BELNR BLART

1000 1000001 RE

1000 1000002 KZ

1000 1000003 KR

1000 1000004 RE

Here I want to delete all the RE u2013Document in ITAB. How do to this one.

Thankx advance,,,,,

1 ACCEPTED SOLUTION
Read only

GauthamV
Active Contributor
0 Likes
2,163

hi,

its always better to use loop if you want to delete multiple records.

check Rich's reply here.

[https://forums.sdn.sap.com/click.jspa?searchID=19735567&messageID=840416]

Hi all,

My Internal table consists of following fields and entries. I want delete particular set of entries without using loop. For example ITAB is:

BUKRS BELNR BLART

1000 1000001 RE

1000 1000002 KZ

1000 1000003 KR

1000 1000004 RE

Here I want to delete all the RE u2013Document in ITAB. How do to this one.

Thankx advance,,,,,

11 REPLIES 11
Read only

Former Member
0 Likes
2,163

Hi

Use

Delete ITAB where BLART = 'RE'.

Regards

Aditya

Read only

Former Member
0 Likes
2,163

HI Durai,

try this

delete itab[] where table-fieldname = " ".

also try this

delete itab from wa with key table-fieldname = " ".

also do a F1 on delete . this can give you very good results.

regards

-Sudipta

Read only

former_member222860
Active Contributor
0 Likes
2,163

Hi,

DELETE FROM ITAB WHERE BLART = 'RE'.

thanks

Mahesh

Read only

0 Likes
2,163

if i want to delete multiple blart types. How can I ???

Read only

GauthamV
Active Contributor
0 Likes
2,164

hi,

its always better to use loop if you want to delete multiple records.

check Rich's reply here.

[https://forums.sdn.sap.com/click.jspa?searchID=19735567&messageID=840416]

Read only

former_member222860
Active Contributor
0 Likes
2,163

Hey,

sorry for the syntax in the previous one.

DELETE ITAB WHERE BLART = 'RE'.

regards

Mahesh

Read only

Former Member
0 Likes
2,163

Hi,

DELETE ITAB WHERE BLART = 'RE'

OR

On delete press in F1 u find more about that......

Read only

Former Member
0 Likes
2,163

DELETE ITAB WHERE VBLEN = '1006758'.

(OR)

DELETE ITAB INDEX 5.

Regards,

Ajay

Read only

Former Member
0 Likes
2,163

Yes,,I tried those statements, but still it is not deleting any rows in my ITAB. Any other way to delete this particular document types.

Thankx,,,,

Read only

Former Member
0 Likes
2,163

This message was moderated.

Read only

mimanchi
Explorer
0 Likes
2,163

hi

Delete ITAB where BLART = 'RE'.