Merging duplicate customers
The same customer ends up in the database twice surprisingly often — once after a phone call, once after a showroom visit. We show how the system detects such pairs, how to combine the records into one and how to undo a merge.
Why merge
A customer called in the morning — a sales adviser created a record. In the afternoon they came to the showroom and ended up with another adviser, who created a second one. After the measurement it turns out that the history of one case sits on two records, and the statistics count it twice.
Merging combines the records into one, moving all documents onto it. Nothing is lost — only the record they belong to changes.
How the system finds duplicates
The customer list has a duplicates-only view. The system matches records by three pieces of data that unambiguously point to the same customer:
- Phone
- Compared by digits only, so spaces, brackets and hyphens don’t matter. Numbers shorter than nine digits are skipped. Write numbers consistently — “+44 7700 900123” and “07700 900123” have different digits, so the system treats them as different numbers.
- Company tax number
- For business customers — the tax number, compared without spaces, dots and hyphens, and only when it has at least five characters.
- Email address
- Case-insensitive, and only one that looks like a real address.
Matches combine transitively: if the first record shares a phone number with the second, and the second shares an email address with the third, all three end up in one group. Groups are marked on the list, and the duplicates view refreshes every minute.
How to merge records
- Select the records on the listIt doesn’t have to be exactly two — you can select all records of the same customer at once.
- Click “Merge” above the listThe button shows how many records the operation will cover.
- Choose the primary recordThis one stays and takes over everything. Choose the one with more complete data — with the tax numbers, address and correct name filled in.
- ConfirmThe operation runs completely or not at all — an interrupted merge won’t leave half the documents on one side and half on the other.
What exactly is moved
- Contracts — including those where the merged record was the payer rather than the buyer
- Measurements — keeping their numbers and dates
- Quotes
- Complaints and service requests
- Addresses — added to the primary record as further entries
- Pins — without duplicates, if both records were pinned by the same person
The merged record disappears from lists and search, but stays in the database with a pointer to the primary record. That way an old link leads to the right place, and the merge can be undone.
Undoing a merge
Every merge is recorded in the history of the primary record. You’ll find it in its preview, on the Merges tab — it only appears if there has been one.
Undoing restores the state from before the operation: documents return to their original owners, addresses to their records together with the main-address flag, and the merged records reappear on the list.
