Homework 1

Due September 20 at beginning of class

The goal of this assignment is to ensure that you've understood enough of the principles of data modeling to be able to be able to really understand the rest of the papers that we're reading.

To do so, the goal is to design a schema in ER diagrams, translate it into relational databases, and then write some queries on it. To make this more real, the goal is to use some data that you have. This assignment is to be done individually - afterall, you all have different data. You may discuss problems that you have with one another, but you should not have the same schemas, queries, or data. Please state any assumptions that you make.

The assignment must be turned in on paper at the beginning of class on the 19th.

  1. Create an ER diagram for some data that you have. The diagram should contain at least 2 relationships and three entities. Make sure you have keys for each entity. (30%)
  2. Create a relational schema based on the ER diagram above. If you can't figure out how to do something based on what was covered in class, that's okay, just write an explanation as to what you did and why.(30%)
  3. Create 3 queries over your schema. You must use selection, projection, and joins at least twice each (e.g., one query with selection, one query with projection and a join, and one query with selection, projection, and join would be fine). Write the queries in SQL, Datalog, and English. (35%)
  4. Answer the following questions (5%):
    1. If you were designing a relational schema, would you bother going for an ER diagram, or would you just go straight for relational? Why?
    2. How long did it take you to complete this assignment?
    3. What did you like the best about this assignment?
    4. What did you like the least about this assignment?
    5. What helped you learn the best in this assignment?
    6. What distracted from your learning in this assignment?


[504 home] [grading] [schedule] [project] [WebCT]

Rachel Pottinger
E-mail Address: rap [at] cs [dot] ubc [dot] ca
Office Location: CICSR 345
Phone: (604)822-0436
Fax:(604)822-5485
Postal/Courier address:
The Department of Computer Science
University of British Columbia
201-2366 Main Mall
Vancouver, B.C. V6T 1Z4
Canada