0% found this document useful (0 votes)
69 views8 pages

Sample ER Diagrams

The document outlines various database design scenarios, including car insurance, hospital patient records, university course management, and sports team statistics. It discusses the creation of Entity-Relationship (E-R) diagrams for different applications, such as tracking student marks, scheduling exams, and managing airline operations. Additionally, it emphasizes the need for relational schemas and constraints in database design for various industries.

Uploaded by

24ads.kishore.s
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
69 views8 pages

Sample ER Diagrams

The document outlines various database design scenarios, including car insurance, hospital patient records, university course management, and sports team statistics. It discusses the creation of Entity-Relationship (E-R) diagrams for different applications, such as tracking student marks, scheduling exams, and managing airline operations. Additionally, it emphasizes the need for relational schemas and constraints in database design for various industries.

Uploaded by

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

1.​ A car-insurance company whose customers own one or more cars each.

Each car
has associated with it zero to any number of recorded accidents.

2.​ A hospital with a set of patients and a set of medical doctors. Associate with each
patient a log of the various tests and examinations conducted.

3.​ A university registrar’s office maintains data about the following entities: (a)
courses, including number, title, credits, syllabus, and prerequisites; (b) course
offerings, including course number, year, semester, section number, instructor(s),
timings, and classroom; (c) students, including student-id, name, and program;
and (d) instructors, including identification number, name, department, and title.
Further, the enrollment of students in courses and grades awarded to students in
each course they are enrolled for must be appropriately modeled.
4.​ Consider a database used to record the marks that students get in different
exams of different course offerings.
a. Construct an E-R diagram that models exams as entities, and uses a ternary
relationship, for the above database.
5.​ Construct an alternative E-R diagram that uses only a binary relationship
between students and course-offerings. Make sure that only one relationship
exists between a particular student and course-offering pair, yet you can
represent the marks that a student gets in different exams of a course offering.

6.​ Design an E-R diagram for keeping track of the exploits of your favourite sports
team. You should store the matches played, the scores in each match, the players
in each match and individual player statistics for each match. Summary statistics
should be modelled as derived attributes

7.​ Extend the E-R diagram of the previous question to track the same information
for all teams in a league.
8.​ Consider the E-R diagram in Figure, which models an online bookstore.
a. List the entity sets and their primary keys.
b. Suppose the bookstore adds music cassettes and compact disks to its
collection. The same music item may be present in cassette or compact disk
format, with differing prices. Extend the E-R diagram to model this addition,
ignoring the effect on shopping baskets.
c. Now extend the E-R diagram, using generalization, to model the case where a
shopping basket.

9.​ Design a database for an automobile company to provide to its dealers to assist them
in maintaining customer records and dealer inventory and to assist sales staff in
ordering cars. Each vehicle is identified by a vehicle identification number (VIN).
Each individual vehicle is a particular model of a particular brand offered by the
company (e.g., the XF is a model of the car brand Jaguar of Tata Motors). Each model
can be offered with a variety of options, but an individual car may have only some
(or none) of the available options. The database needs to store information about
models, brands, and options, as well as information about individual dealers,
customers, and cars. Your design should include an E-R diagram, a set of relational
schemas, and a list of constraints, including primary-key and foreign-key constraints.

10.​Consider a university database for the scheduling of classrooms for final exams.
This database could be modeled as the single entity set exam, with attributes
course-name, section-number, room-number, and time. Alternatively, one or more
additional entity sets could be defined, along with relationship sets to replace
some of the attributes of the exam entity set, as
a. course with attributes name, department, and c-number
b. section with attributes s-number and enrollment, and dependent as a
weak entity set on course
c. room with attributes r-number, capacity, and building
Show an E-R diagram illustrating the use of all three additional entity sets
listed.

11.​Design an ER diagram for the following application. Clearly State the


assumptions you make and justify your assumptions.
1. The system needs to keep track of aircrafts, flight crews, customers and their
itineraries, and flights.
2. Each aircraft has a unique number, maker, model, and capacity.
3. A crew member is either a flight attendant or a pilot. Each crew member has
his/her employee ID, name, job title, and base city. Each crew member serves
several flights and each flight has two co-pilots and several flight attendants.
4. Each customer has a profile (you will need to decide what information to
keep) and may have several itineraries. Each itinerary consists of one or more
flights.
5. Each flight has a unique flight number, a departing city, an arriving city, a
departing time, an arriving time, and number of available seats. Several aircrafts
may fly under the same flight number on different days.

12.​Database Design for Banking Enterprise

You might also like