0% found this document useful (0 votes)
6 views

database sheet2

Uploaded by

norantharwat58
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views

database sheet2

Uploaded by

norantharwat58
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

QUESTION 1:

Imagine that you have been assigned to a team that will be developing an inventory tracking
system. As part of the project startup, your manager has asked each team leader to bring a basic
work plan to the next meeting. At that meeting, these work plans will be analyzed to determine the
overall project timeframe, costs, personnel requirements and software requirements. For now, as
the team leader for the data design team, you have been asked to bring a work plan that identifies
the phases of data design and includes the following information for each phase:
a). a description of the data design phase,
b). the inputs of the phase,
c). the outputs of the phase,
d). a key issue addressed in the phase.
e). a challenge that you can anticipate would occur in the phase.

Please prepare the response you will bring to the meeting.

QUESTION 2: CREATING AN ENTITY-RELATIONSHP DIAGRAM


UPS prides itself on having up-to-date information on the processing and current location of each
shipped item. To do this, UPS relies on a company-wide information system. Shipped items are
the heart of the UPS product tracking information system. Shipped items can be characterized by
item number (unique), weight, dimensions, insurance amount, destination, and final delivery date.
Shipped items are received into the UPS system at a single retail center. Retail centers are
characterized by their type, uniqueID, and address. Shipped items make their way to their
destination via one or more standard UPS transportation events (i.e., flights, truck deliveries).
These transportation events are characterized by a unique scheduleNumber, a type (e.g, flight,
truck), and a delivery Route. Please create an Entity Relationship diagram that captures this
information about the UPS.

QUESTION 3: CREATING A RELATIONAL DATABASE SCHEMA


Production tracking is important in many manufacturing environments (e.g., the pharmaceuticals
industry, children’s toys, etc.). The following ER diagram captures important information in the
tracking of production. Specifically, the ER diagram captures relationships between production
lots (or batches), individual production units, and raw materials.
a) Please convert the ER diagram into a relational database schema. Be certain to indicate
primary keys and referential integrity constraints.
b) Please identify an attribute in the above ER diagram that might represent a composite
attribute and explain why/how it might represent a composite attribute.
c) Please identify an attribute in the ER diagram that could represent a derived attribute and
explain why/how it might represent a derived attribute.
d) The ER diagram/relational database schema contains several instances of data redundancy
Please identify one instance where a data redundancy issue exists.
e) The current ER diagram has the following relationship, “raw materials are used in 0 to
many lots.” Please explain, in the context of the manufacturing environment, how the
meaning changed if the minimal cardinality is changed to “1” (i.e., the relationship
becomes "raw materials are used in 1 to many lots.”)
f) Write in SQL production units entity.

QUESTION 4:
a) Normalization. Normalization is a process within logical design. What is the general
goal of normalization? (Hint: Why is it important to identify and remove partial and
transitive functional dependencies during normalization?)
b) An institute runs various part time and full-time courses. The duration of each course
ranges from 1 year to 2 years. A student can undergo at most one course at a time. The
institution has three departments and only one course can be run by one department. a)
Draw Entity Relationship Diagram. b) Convert E-R Diagram in 3NF.
c) Design a database for a car insurance company that has a set of customers each of
whom owns one or more cars. Each car has associated with it zero to any number of
record accidents. A database should provide the following details to user. 1.Identify all
the entities 2. Identify all the relations 3. E-R diagram 4. Relational model Or A car
insurance company name XYZ that has a set of customers each of whom owns one or
more cars. Each car has associated with it zero to any number of record accidents draw
the ER diagram and convert to 3NF.

QUESTION 5:
a) The craft trading website Itsy! Bitsy! is setting up a database to record sellers and their
products. This requires recording the following information:
• For each seller, their name, contact email, and postal address.
• For each product, its name, price, and number available.
• Which product is from which seller.
• A unique id number for each product.
Draw an entity-relationship (ER) diagram that represents this information. Make sure to
capture the constraints on the relationships involved and designate appropriate primary
keys for the entities.
b) The organizers of the EXAM 2011 international multi-conference need to keep track of
a large collection of workshops associated with the event. Initial requirements analysis
brings out the following information about what needs to be recorded.
• Each workshop has a name, and happens on a particular date — or dates, as some
workshops last more than one day.
• There are several participants, each of which may sign up to one or more workshops.
• For each participant, it is important to record their name, email address, and the
workshops which they wish to attend.
• There are several meeting rooms at the conference venue, each of a fixed capacity.
Meetings rooms are identified by a floor and room number.
• Every workshop needs an allocated meeting room; where a workshop lasts for two
days, it will use the same room on both days.
(a) Draw an entity-relationship diagram suitable for representing this information, in
particular the connections between participants, workshops, rooms, and dates.
(b) For each of the following concepts give a brief description of what it means, and
give an example from your ER diagram for the previous part.
(i) Key
(ii) Composite key
(iii) Total participation
(iv) Key constraint
How is total participation shown in an ER diagram? How is a key constraint shown?
Further analysis reveals additional requirements. However, not all of these can be
captured easily in an ER diagram.
• Each workshop must have an identified organizer among the conference participants.
• No participant may register for two workshops on the same day.
• Every participant must register for at least one workshop.
(i) Identify two of these which can be captured in an ER diagram.
(ii) For those two, show the additions required to your diagram.

c) A database is to be set up to record details of experts on different subjects. The database


will be used to contact experts to be called as witnesses in court cases. The following
information needs to be recorded.
• For each expert, their witness identity number, name, affiliation (e.g., “Edinburgh
University”), and email address.
• For each field of expertise, the name of the field (e.g., “DNA forensics”).
• For each expert, all the fields of expertise that they are expert in.
• For each field of expertise, at most one identified leading expert.
(a) Draw an ER diagram that expresses the requirements for the database. Make sure
that you capture all the constraints on the data mentioned above.
(b) Are there any other natural constraints one might impose on the data that are not
captured by the requirements above? For each such constraint, say whether it would be
possible to modify your ER diagram to include the constraint, and, if so, explain how
this would be done.
d) A university wants to set up a database to record details about its staff, and the
departments they belong to. They intend to record the following information.
• For each member of staff, their staff identity number, name, job title, and salary.
• For each department, its name and address.
• For each member of staff, all departments that they belong to. It is required that every
member of staff belongs to at least one department.
• For each department, the head of department. It is required that each department has
exactly one head of department.
(a) Draw an ER diagram that expresses the requirements for the database. Make sure
that you capture all the constraints on the data mentioned above.
(b) Are there any other natural constraints one might impose on the data that are not
captured by the requirements above? For each such constraint, say whether it would be
possible to modify your ER diagram to include the constraint, and, if so, explain how
this would be done.
QUESTION 6:

a) Complete the normalization process and paste the Normalized forms along with a
brief overview of the rationale behind each of the Normal Forms.
b) After normalizing it write in SQL the final results

Custom Custome Salesperso SalesPers Conta Conta Conta Conta Conta Conta
er ID r Name nID on Name ct 1 ct 1 ct 1 ct 2 ct 2 ct 2
ID Phone ID Phone
1 Contoso 1 John Doe 1 Mary (518) 2 Selen (518)
Jane 456- a 299-
9791 Dura 9999
n
2 Heming 2 Dollie 1 Rober (518) 2 Lance
way Wilde t 456 Wild
Down 7896

c) Complete the normalization process and paste the Normalized forms along with a
brief overview of the rationale behind each of the Normal Forms and write in SQL
the final results.

d) Convert the following tables into 3NF.

managerName area employeeID employeeName sectorID sectorName


1 Adam A. East 1 David D. 4 Finance
2 Eugene E. 3 IT
2 Betty B. West 3 George G. 2 Security
4 Henry H. 1 Administration
5 Ingrid I. 4 Finance
3 Carl C. North 6 James J. 1 Administration
7 Katy K. 4 Finance

QUESTION 7:
a) Translate the following ER Diagram into a relational database schema.

b) What ER Diagram might produce the following relational database schema? And write
in SQL every entity in the final form.

You might also like