The script below can be used to find any AP Bill with a duplicated invoice number
select Vendor_Code,
b.Invoice_Number, Count(b.Invoice_Number) as "Number of Bills with Duplicate Invoice Number"
from AP_Vendor a, AP_Invoice b
where a.Vendor_Id = b.Vendor_Id
Group by a.vendor_code, b.invoice_Number
having count(b.invoice_number) >1