Refer to the assignment 3 for
definitions of what is meant by a database design outline and an
entity-relationship diagram. In all three questions, assume you not
have access to a zip code table.
Q1. Jersey Harbor Patrol: You have been assigned the task of automating the records of the Jersey Harbor Patrol Agency. This agency sends patrol boats throughout the Jersey Harbor area, checking for safety and security problems. The agency owns a fleet of boats; for each boat, you want to store its (unique) marine registration number, name, date built, and date acquired. The boats are operated by employees, for each of whom you want to store an employee number, first name, last name, date of birth, date hired, cell phone number, home phone number, home street address, city, state, and zip code.
The employees use the boats to visit various sites around the harbor. Each site has a "site number", name, and description. Each time a boat leaves the agency's home dock is called a "patrol". Each patrol involves two employees, a "captain" and an "assistant". The captain is responsible for all decisions on the patrol, and the assistant must follow his orders. However, an employee who is the captain of one patrol might be the assistant on a different patrol. For each patrol, you want to record which boat was involved, who the captain and assistant were, what date and time the patrol started, and what date and time it ended. Each patrol involves visits to one or more sites; generally, the agency tries to visit each site at least once every few days. You want to record the set of sites visited by each patrol, and the exact date and time of each visit.
Design a database to store this information. Draw an entity-relationship diagram and write a database
design outline. You may add "ID" fields where necessary.
Q2. Query Exercises: From the class website entries for November 5, download the file conference.mdb, which describes the sessions and speakers at a conference:
Q3. Normalizing Temporary Employment Records: The following table keeps track of temporary worker assignments at a firm, one row per assignment:
|
Assignment ID |
Temp |
Temp |
Dept |
Dept |
Job |
Job |
|
Hours |
Rate |
| 11772 |
1013 |
Bill Wong |
ENG |
Engineering |
TC |
Technical Consulting |
2/27/2007 |
3 |
$100 |
| 11765 |
1015 |
Melanie
East |
MKT |
Marketing |
TC |
Technical Consulting |
1/25/2007 |
4 |
$120 |
| 11767 |
2051 |
Ed North |
ACT |
Accounting |
CLR |
Clerical |
1/31/2007 |
2 |
$50 |
| 11768 |
2051 |
Ed North |
MKT |
Marketing |
CLR |
Clerical |
2/10/2007 |
4 |
$55 |
| 11769 |
3356 |
John Edokway |
SLS |
Sales |
SC |
Strategic Consulting |
2/15/2007 |
5 |
$90 |
| 11773 |
3356 |
John Edokway |
MKT |
Marketing |
EDT |
Editing |
3/20/2007 |
6 |
$60 |
| 11771 |
4076 |
Marissa Estevez |
ENG |
Engineering |
EDT |
Editing |
2/26/2007 |
7 |
$65 |
| 11766 |
4079 |
Hannah Goldberg |
ENG |
Engineering |
TC |
Technical Consulting |
1/25/2007 |
4 |
$110 |
| 11770 |
4079 |
Hannah Goldberg |
MKT |
Marketing |
EDT |
Editing |
2/25/2007 |
5 |
$70 |
Note that the rate per hour is negotiated separately for each assignment.
Design a third-normal-form database storing the same information Draw an entity-relationship diagram and write a database design outline. Note: this problem is not as complicated as the normalization problem in assignment 6.