Project 3.0

Jan 23, 2012

Objective

Design a schema using the Entity-Relationship model, producing an ERD.

Scenario

"Hey, I found your keys!" your roommate proudly proclaims, jingling your keys from his finger. "How is that database coming along? I wish I could take Professor Bakos' class, I hear he's an easy A."

"Are you kidding me?" you reply as you grab your keys from his hands, "Easy A? We have daily quizzes and projects and his jokes are terrible! Anyway, I think I should be able to come up with a good database for you, but I need to figure out how to best model the data. See, we learned that instead of keeping data in an unmaintainable flat file like your spreadsheet we really should model things like they are in the real world. You know, with entities, attributes and relationships. See, an entity is..."

You suddenly notice your roommate is drooling and his eyes have glazed over. "Uhhh... what do you mean?" he says.

"Look," you say, growing impatient, "the other night while we were playing Twister at Phi Kappa Sigma you kept talking my ear off about how you wanted to have an application where you could create, view, update and delete a bunch of data independently."

"Yeah, I thought you gave me that Ruby program that basically does just that," your roommate responds.

"Sort of. What about manipulating just wine manufacturers? Or if you want to search for all the wines from a particular region or vintage? Or if you wanted to rate a particular vintage differently than another? Or what if you want to add a comment about a manufacturer and not just a specific bottle of wine?"

"Heyyy, do I hear an ice cream truck outside?" By the time you look up, your roomie has disappeared.

Requirements

In project 2.0 you created a database with a single table, imported from flat-file spreadsheet data.

But if you think about it, that spreadsheet is really making a poor attempt at modeling what it should. For example, a manufacturer is a real-world object, so in theory it should be an entity, not just part of a wine's name.

Your goal for this assignment is to create an ERD that properly follows the ER paradigm.

What entities do you need to model? What are the attributes (limit yourself to what is in the spreadsheet and mentioned below)?

Draw (by hand or via software) an ERD that properly models the following entities:

Be as specific as you can with the attribute types (are any compound? multivalued? Is there a key?). Be sure to indicate the relationships, cardinality, degree of participation and use semantically meaningful names (no generic "has a" or "is related to" relationship names).

Save this ERD and call it wine.erd.xxx, where xxx is the proper file extension (jpg, png, pdf, doc, etc). If you draw this by hand, you will need to scan it or hand in a hard copy.

Hints

Not sure what the entities listed above mean? Be sure to ask in class or via Piazza.

Grading Criteria (120 pts)

Submit your ERD to blackboard.

This is due by midnight on Monday, January 30.