Call Girl In Zirakpur ❤️♀️@ 9988299661 Zirakpur Call Girls Near Me ❤️♀️@ Sexy...
Sree Dattha Institute of Engineering and Science
1. Relations and Relationships sets
Characteristics of a Relation:
Uniqueness of Rows: In a relation, each row must be unique, and no two rows can be identical. This uniqueness is
enforced through a primary key
Atomic Values: Each cell in a relation should contain atomic values, meaning that it cannot be divided further. This
ensures data integrity and simplifies data manipulation.
Attribute Names: Each column in a relation is associated with an attribute name that describes the type of data it
holds.
Ordering of Rows: Rows in a relation have no inherent order. The DBMS handles the physical storage and retrieval of
rows.
No Duplicate Rows: A relation cannot contain duplicate rows. The DBMS ensures that each row is unique.
2. A relationship is defined as an association among several entities.
Example: Enrolled-in is a relationship that exists between entities Student and Course.
Relationship Set
3. Examples of Relations:
To illustrate the concept of relations, consider the following examples:
StudentID Name Age GPA
101 Alice 20 3.7
102 Bob 22 3.5
103 Charlie 21 3.9
EmployeeID First Name Last Name Department
001 John Doe HR
002 Jane Smith IT
003 Sarah Johnson Marketing
4. Relationship Set
The arity of a relationship set specifies the number of participating relations. It can be binary
(involving two relations), ternary (involving three relations), and so on.
Degree: The degree of a relationship set refers to the number of attributes associated with the
relationship set.
Cardinality: Cardinality defines the number of instances or records that can be associated with each
entity on both sides of the relationship. It is classified into one-to-one, one-to-many, or many-to-many
cardinality.
5. Arity refers to the number of columns in a table. If a table has five columns (as in
the case of the customer entity above), we say it is of arity 5.
7. 1. Unary Relationship Set-
One person is married to only one person
2. Binary Relationship Set-
Binary relationship set is a relationship set where two entity sets participate in a relationship set.
8. 3. Ternary Relationship Set-
Ternary relationship set is a relationship set where three entity sets participate in a relationship set.
N-ary relationship set is a relationship set where ‘n’ entity sets participate in a relationship set.
9. Additional Features of the ER Model in DBMS
.
Generalization is the process of extracting common properties from a set of entities and
creating a generalized entity from it.
It is a bottom-up approach in which two or more entities can be generalized to a higher-
level entity if they have some attributes in common.
10. Common attributes like P_NAME, and P_ADD become part of a higher entity
(PERSON), and specialized attributes like S_FEE become part of a specialized entity
(STUDENT).
11. Specialization
In specialization, an entity is divided into sub-entities based on its characteristics.
It is a top-down approach where the higher-level entity is specialized into two or more lower-level entities.
For Example, an EMPLOYEE entity in an Employee management system can be specialized into DEVELOPER,
TESTER.
In this case, common attributes like E_NAME, E_SAL, etc. become part of a higher entity (EMPLOYEE), and
specialized attributes like TES_TYPE become part of a specialized entity (TESTER).
12. Aggregation
An ER diagram is not capable of representing the relationship between an entity and a relationship
which may be required in some scenarios.
In those cases, a relationship with its corresponding entities is aggregated into a higher-level entity.
Aggregation is an abstraction through which we can represent relationships as higher-level entity sets.