FWIW I would do it slightly different
1) I would make sure duplicate detection is turned on in
Preferences: Adding Books:
When using Copy to Library
Preferences: Adding Books: Automerge:
2) Create a new (Empty Library).: (your choice) Overwrite or Ignore
<suggest a backup of your old Library, just in case>
3)Select some books in old library: (right-click)Copy to Library

Delete, so the list gets smaller): REPEAT
True Dups, get merged. Multiple formats get merged

All that is missing is what source was the best quality