0% found this document useful (0 votes)
20 views25 pages

ERD-02 Part II

This document provides information on entity relationship diagrams (ERDs), including: - Characteristics of composite attributes, multivalued attributes, and primary keys. - Examples of simple, composite, and multivalued attributes. - Definitions of minimum and maximum cardinality constraints between entities. - An example ERD modeling cinemas, theaters, showings, and movies with identifying attributes and relationships between entities.

Uploaded by

seerat fatima
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views25 pages

ERD-02 Part II

This document provides information on entity relationship diagrams (ERDs), including: - Characteristics of composite attributes, multivalued attributes, and primary keys. - Examples of simple, composite, and multivalued attributes. - Definitions of minimum and maximum cardinality constraints between entities. - An example ERD modeling cinemas, theaters, showings, and movies with identifying attributes and relationships between entities.

Uploaded by

seerat fatima
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 25

ERD Part II

Ms Zahra Ali
Composite Attribute
• A simple attribute is one component that is
atomic. A composite attribute has multiple
components.
Composite Attribute
Multivalued Attribute
Characteristics of Identifies (Primary
Key)
• Will not change
• Will not be null
Exercise
Classifications the following attributes (simple,composite,multivalued):
• First Name
• Full Name
• Years Employed
• Race
• Roll no
• Hobbies
• Date Employed
• Password
• Today’s Date
• Last Name
• TransactionID
CARDINALITY CONSTRAINTS
• Cardinality Constraints - the number of instances
of one entity that can or must be associated with
each instance of another entity
• Minimum Cardinality
• If zero, then optional
• If one or more, then mandatory
• Maximum Cardinality
• The maximum number
Exercise
• Odeon Cinema and other international
cinemas have decided to install a centralized
database. This database should keep
information regarding cinemas including its
name, address and phone number. Each
cinema must have one or more theaters and
each theater has a specific showing time.
During these showing times a movie is shown
to the general public
solution
• ATTRIBUTES
• CINEMA
– Cinema_ID
– Cinema_Name
– Cinema_Address
– Cinema_Phone
• THEATER
– Theater_ID
– Theater_Capacity
• SHOWING
– Showing_Time
– Showing_Date
– Showing_Attendence
• MOVIE
• Movie_ID
– Movie_Title
– Movie_Director
– Movie_Rating
Step 3

BUSINESS RULES
• A CINEMA must contain one or more THEATERS. A THEATER must belong to one
CINEMA only.
• A THEATER has one or more SHOWING times. A particular SHOWING time for a
movie must belong to one THEATER only
• A MOVIE can have many SHOWING times and a particular SHOWING time at a
THEATER must belong to one MOVIE only.
Step 4
Announcements
• Quiz No 2 will be held in upcoming class.
• Final Project ERD is due , uploaded on LMS.

You might also like