10-26-2006 6:55 PM
Hi Experts,
I have two field-symbols internal tables <itab>, <items>. I want to delete all records in <itab> if they are existing in <items>. I can complete it by doing LOOP but it's time-consuming. Is there any better way to do it?
Thanks.
Tom
10-26-2006 6:57 PM
Hi,
I don't think there if there is any other technique to solve other than using LOOP AT ...
Thanks,
Naren
10-26-2006 6:57 PM
Hi,
I don't think there if there is any other technique to solve other than using LOOP AT ...
Thanks,
Naren
10-26-2006 7:02 PM
You could use the following
DELETE itab WHERE field like '*'.
or
DESCRIBE TABLE itab LINES idx2.
DELETE itab FROM 1 TO idx2.
Regards,
Dennis
10-26-2006 7:02 PM
If you do a binary search on the second table, it won't take as much time. If there are multiple records in the second table for records in the first table you can use an indexed read to get rid of those.
Rob