Skip to content
C

Tuple


Tuple

Definition

A tuple is a single ordered n-tuple of values — one value per attribute of the relation's schema — representing one entity or fact within a relation. If the schema has degree n, every tuple in that relation is an n-tuple: (v1, v2, ..., vn) where each vi belongs to the domain Di of its attribute.

Example

In Students(id, name, department, gpa), the tuple (3, Meera, CS, 9.1) represents one student's data. The relation is the entire set of such tuples; a tuple is just one element (one row) of that set.

How this differs from Relation / Attribute

  • A Relation is the whole set of tuples; a Tuple is a single member of that set — the relationship is set-to-element, not two views of the same thing.
  • An Attribute is a column name/role (e.g., "gpa"); a Tuple is a complete row of values spanning ALL attributes (e.g., 9.1 is the value the "gpa" attribute takes inside one specific tuple).

Edge Cases

  • Duplicate tuples are disallowed in a strict relation: (3,Meera,CS,9.1) can logically appear only once, no matter how many times an application tries to add it.
  • A tuple containing NULLs, e.g. (5, Ganesh, NULL, NULL), is still a single, well-formed tuple — but see Null Values for how NULLs complicate the "no duplicate tuples" guarantee.
  • The order of tuples within a relation carries no meaning: {(1,...),(2,...)} and {(2,...),(1,...)} are the same relation.

Key Takeaways / Q&A

Q: How many values does one tuple hold? A: Exactly as many as the degree of the relation — one value per attribute.

Q: Can two distinct tuples in the same relation have every corresponding value equal? A: No — if all values match, they are the same set element, meaning it is one tuple, not two.

Mock Test

  • Tuple - Quick Test

    8 questions on Tuple.

    8 questions · 8 min · Medium
    Start Mock Test