How do you approach deduplication when the dataset has no reliable unique identifier?

Quick Overview

Describe how you would deduplicate records when no trustworthy unique ID exists, from cleaning fields to grouping near-matches into entities. It tests entity resolution skills: normalization, candidate generation at scale, similarity scoring, merge rules and validating match quality.

How do you approach deduplication when the dataset has no reliable unique identifier?

Role: Data Scientist

Category: Data Manipulation (SQL/Python)

Difficulty: medium

Interview Round: Other

How do you approach deduplication when the dataset has no reliable unique identifier? For example, customer records arrive from several sources, and the same person can show up with different spellings of a name, different phone formats or a second email address. ```hint Two kinds of duplicates Separate records that become identical after cleanup from records that only look alike. They call for different tools. ``` ```hint Watch the pair count Scoring every pair of records grows with the square of the row count. Think about how to shrink the set of pairs you compare. ``` ### Clarifying Questions to Ask - What entity is being deduplicated (people, companies, products), and which fields are usually filled in? - Roughly how many records are there, and do new ones arrive continuously? - Which error is more costly here: merging two different entities or leaving a duplicate in place? - Is there any labeled set of known matches, or a team that can review uncertain pairs? ### What a Strong Answer Covers - Cleaning and standardizing fields before any comparison - Exact matching on a composite key built from stable attributes - How candidate pairs are generated at scale and how they are scored - How matched records are grouped and merged into one surviving record - How thresholds are validated before an irreversible merge ### Follow-up Questions - How would you choose the match threshold, and what does that choice trade off? - Record A matches B and B matches C, but A and C look different. How do you handle that? - How would you keep the dataset deduplicated as new records arrive every day? - How would you measure match quality if you had no labeled pairs at all?

Overview: Describe how you would deduplicate records when no trustworthy unique ID exists, from cleaning fields to grouping near-matches into entities. It tests entity resolution skills: normalization, candidate generation at scale, similarity scoring, merge rules and validating match quality.

PracHub logo
General
Nov 24, 2026
mediumData ScientistOtherData Manipulation (SQL/Python)
0
0

How do you approach deduplication when the dataset has no reliable unique identifier?

For example, customer records arrive from several sources, and the same person can show up with different spellings of a name, different phone formats or a second email address.

Clarifying Questions to Ask Guidance

  • What entity is being deduplicated (people, companies, products), and which fields are usually filled in?
  • Roughly how many records are there, and do new ones arrive continuously?
  • Which error is more costly here: merging two different entities or leaving a duplicate in place?
  • Is there any labeled set of known matches, or a team that can review uncertain pairs?

What a Strong Answer Covers Guidance

  • Cleaning and standardizing fields before any comparison
  • Exact matching on a composite key built from stable attributes
  • How candidate pairs are generated at scale and how they are scored
  • How matched records are grouped and merged into one surviving record
  • How thresholds are validated before an irreversible merge

Follow-up Questions Guidance

  • How would you choose the match threshold, and what does that choice trade off?
  • Record A matches B and B matches C, but A and C look different. How do you handle that?
  • How would you keep the dataset deduplicated as new records arrive every day?
  • How would you measure match quality if you had no labeled pairs at all?