Single Valued Attribute
Single Valued Attribute
Definition
A single-valued attribute is an attribute that holds exactly one value for any given entity at any point in time. This is the default and most common kind of attribute; it contrasts directly with a multi-valued attribute (6.9), which can hold a set of several values for one entity simultaneously.
Worked Example
In the Student entity set, Date_of_Birth is single-valued — a student has exactly one date of birth, never two. Roll_No is also single-valued — one student has exactly one roll number. Contrast this with Phone_Number: if the college allows students to register more than one contact number, Phone_Number becomes multi-valued rather than single-valued.
Edge Cases
- "Single-valued" describes cardinality of occurrence (how many instances of that attribute one entity can have), which is a completely different axis from simple vs. composite (6.6/6.7), which describes internal structure.
Date_of_Birthis both simple AND single-valued;Addresscan be composite AND single-valued (one address, with sub-parts) at the same time. - Even an attribute that is usually single-valued in casual conversation can be modeled as multi-valued if the business rules allow it — e.g.,
Emailis often assumed single-valued, but if the college allows a personal AND an institutional email per student, it must be re-modeled as multi-valued. - A single-valued attribute can still be NULL (missing/unknown) — "single-valued" does not mean "always has a value," it means "cannot have more than one simultaneous value."
- In ER-to-relational mapping, single-valued attributes map cleanly to a single column in the entity's table; this is precisely why multi-valued attributes cannot do the same (see 6.9) and instead require a separate table.
Key Takeaways / Interview Q&A
Q: What is the defining test for single-valued vs. multi-valued? A: Ask: "Can this entity legitimately have more than one simultaneous value for this attribute?" If no, it is single-valued.
Q: Are Roll_No and CGPA single-valued attributes? A: Yes — a student has exactly one roll number and, at any given time, one CGPA value.
Q: Is single-valued the "default" assumption for attributes in ER modeling? A: Yes — unless a business requirement explicitly demands multiple simultaneous values (like several phone numbers or several skills), attributes are modeled as single-valued.