AI engineering glossary · SQL databases
What is candidate key?
Candidate key: Any minimal set of columns that could uniquely identify every row, meaning no column can be removed without losing uniqueness. A table may have several; one is chosen as the primary key and the rest remain alternatives.
Candidate key: an example
In an employees table, both employee_id and official_email are unique, so each is a candidate key; the team picks employee_id as the primary key.
Related terms
More SQL databases terms
- CAP theorem
- Cardinality
- CASE expression
- Check constraint
- Clustered index
- COALESCE
- Column
- COMMIT and ROLLBACK
Where you learn it
Candidate key is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.