Lecture05 IDB
Lecture05 IDB
PART 01
Course Code: CSC 2108 Course Title: Introduction To Database
ER Diagram
Alternative ER Notation
Participation
Cardinality Limits
Keys
Weak Entity Set
Generalization
Specialization
Aggregation
ER Diagram
Notation
Rectangles represent entity sets.
Diamonds represent relationship
sets.
Lines link attributes to entity sets
and entity sets to relationship
sets.
Ellipses represent attributes
Double ellipses represent
multivalued attributes.
Dashed ellipses denote
derived attributes.
Underline indicates primary key
attributes
ER Diagram
Entity Sets
• A super key of an entity set is a set of one or more attributes whose values
uniquely determine each entity.
• A candidate key of an entity set is a minimal super key
• Although several candidate keys may exist, one of the candidate keys is
selected to be the primary key.
• Every candidate key is a super key but, every super key may or may not be
a candidate key.
• Foreign Key of the entity attribute is the entity which is the primary key of
the related entity. Foreign key helps to establish the mapping between two
or more entities.
Weak Entity Sets
• An entity set that does not have a primary key is referred to as a weak
entity set.
• The existence of a weak entity set depends on the existence of a
identifying entity set
It must relate to the identifying entity set via a total; one-to-many
relationship set from the identifying to the weak entity set
Identifying relationship depicted using a double diamond
• The discriminator (or partial key) of a weak entity set is the set of
attributes that distinguishes among all the entities of a weak entity set.
• The primary key of a weak entity set is formed by the primary key of the
strong entity set on which the weak entity set is existence dependent,
plus the weak entity set’s discriminator.
Weak Entity Sets
1. https://www.db-book.com/db6/slide-dir/index.html
2. https://docs.oracle.com/en/database/oracle/oracle-database/20/sqlrf/SQL-Sta
ndards.html#GUID-BCCCFF75-D2A4-43AD-8CAF-C3C97D92AC63
3. https://www.slideshare.net/HaaMeemMohiyuddin1/data-knowledge-and-infor
mation
4. https://www.slideshare.net/tabinhasan/from-data-to-wisdom
5. https://www.slideshare.net/thinnaphat.bo/