-
Notifications
You must be signed in to change notification settings - Fork 1
Merging duplicate players
After importing PGN files you may find the same player listed twice — for example a full name "Krejcar, Walter" and a surname-only "Krejcar", each with their own games. This happens when different PGN sources spell the same player differently (full name vs surname only, "Lastname, Firstname" vs "Firstname Lastname", accents or spelling differences, …).
LPDO's automatic players dedup only merges records that share the same
FIDE ID, so it can't combine these on its own — the surname-only record
usually has no FIDE ID. For those, you merge the records yourself.
Close the LPDO app first so it isn't holding the database open, then run the
bundled chess-db command line. Keep the better record (usually the full,
FIDE-linked name) and merge the other into it:
chess-db players merge-by-name "Krejcar, Walter" "Krejcar"- The first name is kept; the second is deleted and all of its games move onto the first.
- Type the names exactly as they appear in the app.
- You'll be asked to confirm — add
--yesto skip the prompt.
If the names are similar enough that merge-by-name is ambiguous, merge by ID.
First find the IDs:
chess-db search players "Krejcar"then merge (keep first, drop second):
chess-db players merge <keep-id> <drop-id>If the duplicates carry the same FIDE ID (often the case when the same player was imported from different files), merge all such pairs in one go:
chess-db players dedup- The database is at
~/.chess-db/chess.dbby default — no path needed. - Close the LPDO app before running these commands. While the app is open it holds the database, and the command won't be able to open it.
- Merging is permanent: the dropped record is deleted and its games are reassigned to the kept player, whose name is the one that remains.
A Merge players feature is on the way — a "Merge…" button on a player's view and a tool under Maintenance → Merge players — so you'll be able to do all of this without the command line. This page will be updated when it ships.