Key definition: is a key a set of one or more attributes that uniquely identifies a row (tuple) in a relation?

Difficulty: Easy

Correct Answer: Correct

Explanation:


Introduction / Context:
Keys are central to relational design. This question checks the basic definition of a key in a relation and whether it uniquely identifies tuples.



Given Data / Assumptions:

  • We consider candidate keys and the chosen primary key.
  • A key can consist of one attribute or a combination (composite key).
  • Uniqueness is the defining property; minimality defines a candidate key.


Concept / Approach:
A key is any minimal superkey: it uniquely identifies rows and no proper subset does. The statement focuses on uniqueness, which is correct. Whether a key is selected as the primary key is a naming and implementation choice; it does not affect the definition.



Step-by-Step Solution:

Recall: superkey = attributes whose combined values are unique across tuples.Key (candidate key) = minimal superkey.Therefore, a key does uniquely identify a row.


Verification / Alternative check:
In SQL, declare UNIQUE constraints (or PRIMARY KEY) to enforce uniqueness, reflecting the theoretical concept.



Why Other Options Are Wrong:

  • “Incorrect” contradicts the fundamental definition.
  • Limiting to primary key is unnecessary; all candidate keys uniquely identify rows.
  • Numeric types are irrelevant; keys can be strings, dates, etc.


Common Pitfalls:
Confusing “primary key” (one chosen key) with the general concept of “key” (candidate keys).



Final Answer:
Correct

Discussion & Comments

No comments yet. Be the first to comment!
Join Discussion