V4 to V5 migration error - database


After starting the migration process from V4 to V5 it fails with an error while importing invoices. It imports 58 invoices out of 6219 and always fails on the same one:

[2021-01-24 21:12:12] production.INFO: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry ‘146-62’ for key ‘invoice_invitations_client_contact_id_invoice_id_unique’ (SQL: insert into invoice_invitations (company_id, user_id, client_contact_id, invoice_id, key, transaction_reference, message_id, email_error, signature_base64, signature_date, sent_date, viewed_date, opened_date, id, created_at, updated_at, deleted_at) values (2, 1, 146, 62, x3zapvm457fxkp54i6yahfzxnp5qmo7l, ?, 0, ?, ?, ?, 2019-01-10 11:53:05, ?, ?, 399, 2019-01-10 00:00:00.000000, 2019-01-10 00:00:00.000000, ?))

I looked around the database a bit and cant find that entry. What would be the best way to fix this?

Thank you for your time.

which version of v4 and v5 are you using?


Both were latest at the time of writting - V4 is 4.5.31 and v5 is v5.0.52-C38.