1 / 13

CGS 2545: Database Concepts Spring 2012 Chapter 3 – In Class Exercises

CGS 2545: Database Concepts Spring 2012 Chapter 3 – In Class Exercises. Instructor : Dr. Mark Llewellyn markl@cs.ucf.edu HEC 236, 407-823-2790 http://www.cs.ucf.edu/courses/cgs2545/spr2012. Department of Electrical Engineering and Computer Science Computer Science Division

auryon
Download Presentation

CGS 2545: Database Concepts Spring 2012 Chapter 3 – In Class Exercises

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CGS 2545: Database Concepts Spring 2012 Chapter 3 – In Class Exercises Instructor : Dr. Mark Llewellyn markl@cs.ucf.edu HEC 236, 407-823-2790 http://www.cs.ucf.edu/courses/cgs2545/spr2012 Department of Electrical Engineering and Computer Science Computer Science Division University of Central Florida

  2. Problem #1 Add a subtype discriminator for each of the supertypes shown in the ERD.

  3. Solution to Problem #1

  4. Construct an ERD for the following scenario: A nonprofit organization depends on a number of different types of persons for its successful operation. The organization is interested in the following attributes for all of these persons: SSN, Name, Address, City/State/Zip, and Telephone. Three types of persons are of greatest interest: employees, volunteers, and donors. Employees have only a Date_hired attribute, and volunteers have only a Skill attribute (assume multi-valued). Donors have only a relationship (named Donates) with an Item entity type. A donor must have donated one or more items, and an item may have no donors, or one or more donors. Problem #2

  5. ERD For Problem #2

  6. Modify this ERD to incorporate the following business rules: 1: For a section of a course to be scheduled there must be a faculty member qualified to teach it. 2. For a student to register in a section of a course, that student must not be registered in a total of more than 6 courses sections. Problem #3

  7. ERD For Problem #3

  8. Problem #4 Incorporate the following business rule into this ERD: A resident patient can be assigned a bed only if that patient has been assigned a responsible physician. What is the anchor object? What is the corresponding object?

  9. ERD For Problem #4 Anchor object: resident patient Corresponding object: responsible physician

  10. Consider the following business rule: “A student may attend a concert only if that student has completed their homework assignment.” Draw an ERD that portrays the entities and relationships in this rule. Add the notation to incorporate this rule in the ERD. What is the anchor object? What is the corresponding object? Problem #5

  11. ERD For Problem #5 Anchor object: student Corresponding object: has_completed (homework)

  12. Scenario #6 Develop entity clusters for this ERD and redraw using the entity clusters

  13. ERD For Problem #6 Using Clustering

More Related