Skip to content
Exit presentation

Data Handling II: Databases & Structured Data

The naming value

One value should name exactly one record. To name a record is to point to that one record only.

Four rows from the register.
Step 1 of 4
  1. Four rows from the register.
  2. Every admission number here is different.
  3. Two rows share this same name.
  4. Their admission numbers still tell them apart.

The rule

A key is a column whose values each name exactly one record. A single value names a record when only one record carries it.

Ask this register for "Ananya Suresh." Two records answer: A-108 and A-110. The name cannot say which one the office meant. So it names neither.

Look at the other columns too. Seven records share the section 9-A. Four share the due 1450. Only admission has no shared value.

Admission numbers are different by design. The school hands out one per student and never reuses it. That makes admission a key. The name column is not one.

Below are eight values to test. Sort each one by how many records carry it.

Loading lab…

Uniqueness means only one record carries the value. Uniqueness alone decides whether a value names a record. A value's length or look does not decide it.

Jump to lesson

This track

  1. 0 Start here
  2. 1 One record, one row
  3. 2 The naming value
  4. 3 Naming the columns
  5. 4 Asking the register one question
  6. 5 Two conditions, both true
  7. 6 The answer, in order
  8. 7 Counting the groups in the answer
  9. 8 What a database adds
  10. 9 The big picture
  11. 10 Track quiz

Other tracks