1. In Microsoft SQL Server Management Studio, access the appropriate application database. Then, run the following statement to determine whether duplicate records exist in the INTran table.
SELECT InvtID, TranAmt, LineRef, RecordID, * FROM INTran WHERE BatNbr = '<XXXXXX>'
Note: In the statement, replace the <XXXXXX> placeholder with the batch number.
2. Review the results to determine whether duplicate records exist. If a duplicate record exists, run the following statement to delete it.
Note: The recordid to delete would be the HIGHER of the duplicate records.
Run this first:
Run this Next: DELETE FROM INTran WHERE BatNbr = '<XXXXXX>' and RecordID = <YYYYYY>
Note In the statement, replace the <XXXXXX> placeholder with the batch number. Replace the <YYYYYY> placeholder with the RecordID value of the record that you want to delete.
The delete should return 1 row
Run this last:
If it does not delete just one row
If you find more than one duplicate, you have to identify the recordid (unique) for the other duplicates and delete them by using the same procedure.
ID članka: 2953073 - Poslednji pregled: 03.02.2017. - Verzija: 2