‎2006 Oct 06 4:28 PM
I want to delete duplicate records from an Internal Table by comparing all the fields.
CAN I use the code below or do i need to specify comparing fields.
DELETE ADJACENT DUPLICATES FROM it_bsid.
Shejal.
‎2006 Oct 06 4:30 PM
Hi,
Example..
For DELETE ADJACENT DUPLICATES you have to sort first..
SORT ITAB BY MATNR.
DELETE ADJACENT DUPLICATES FROM ITAB COMPARING MATNR.
If you don't give the comparing it will check for all the fields..
Thanks,
Naren
‎2006 Oct 06 4:30 PM
Hi,
Example..
For DELETE ADJACENT DUPLICATES you have to sort first..
SORT ITAB BY MATNR.
DELETE ADJACENT DUPLICATES FROM ITAB COMPARING MATNR.
If you don't give the comparing it will check for all the fields..
Thanks,
Naren
‎2006 Oct 06 4:30 PM
‎2006 Oct 06 4:30 PM
<b>DELETE ADJACENT DUPLICATES FROM it_bsid comparing all fields.</b>
Don't forget to sort.
‎2006 Oct 06 4:31 PM
Hi Shejal,
If you didnt specify COMPARING clause it will consider all fields of internal table.
These two statements will work in same manner.
DELETE ADJACENT DUPLICATES FROM it_bsid.
DELETE ADJACENT DUPLICATES FROM it_bsid COMPARING ALL FIELDS.
Thanks,
Vinay
‎2006 Oct 06 4:32 PM