‎2017 Oct 26 2:23 PM
Hi ,
Currently im using ECC 6.0 EHP 8.0 version.
i need to delete duplicate records in database table S111. For deletion im using the statement.
Loop at...
DELETE S111 FROM gw_table.
endloop.

But the system is throwing run time error. that is the system is not allowing to delete multiple duplicate records using the work area.

the below logic works for deleting multiple records. but taking too much time and performance is too poor. any idea to resolve this issue.
loop at ..
DELETE S111 FROM TABLE gi_table.
endloop.
‎2017 Oct 26 2:59 PM
How was this data inserted in database, bypassing Primary Key constraint, primary index inactive?
The OPEN SQL delete will use primary key values to identify records to delete, here with same keys you get only one record and database raise an error.
Did you
Else could you try to (as a last tricky solution)
‎2017 Oct 26 3:22 PM
hi recently they had upgraded the ecc system. we cannot go for mass deletion since its a standard sap table.
I had written the code as below. her gi_s111_final table contains the duplicate records.
in order to check how many records in data base i'm using select statement in and getting in gi_table.
then im trying to delete records based on gi_table internal table. since work area deletion is throwing run time error (please see my previous post for run time error.)
the below code is working fine. but performance wise poor. any idea to improve performance.


‎2017 Oct 27 6:31 AM