Hey guys!
I'm a newbie at databases and ER diagrams, and I need help with describing this ER-diagram.
I'm having problems with describing "Wine" - "Stocked" - "Inventory". I've learned that "Stocked" is an identifying relationship type and that "Inventory" is a weak entity type. But I have no idea how to describe it in words!
I hope someone can help me with this! :)

Recommended Answers

All 5 Replies

What ever you have posted here is not an E-R diagram.

What ever you have posted here is not an E-R diagram.

What do you call it then?
The instructions before the so called diagram says "Given the ER diagram shown below describe (in an organized way) as much as you can about the real world that the diagram represents."
Also, it looks the same as the ones over at Wikipedia.

Can you please explain what are the following in your ER ?

1. logs_in
2. lives_in
3. consists of
4. classed as
5. makes
6. stocked

etc etc....

Okay, so this picture shows a variant on a old-style Chen diagram. Basically, rectangles are entities, ovals are entities, rounded rectangles are attributes, rounded rectangles with underlined words are keys, diamonds are relationships.

See the "1" and "M" notations on the lines? They tell you which is the parent and which is the child. What it DOESN'T show you is how foreign keys would migrate.

So, for example, you could say "[1] Order(s) Consist(s) of [m]any Items"...you could say "One Wine is stocked as Many Inventory(s)". As you can see, you have to use your imagination a little on these. Then for attributes, you could say "A Winery has winery_id as it's unique identifier, and it's sole attribute is winery_name". As you can see, this would get very tedious very fast. But that's how you would do it. Try a few yourself and post them so I can see if you've got the idea.

One reason this type of notation was supplanted in the '80s and '90s with IDEF style notation or Martin style notation ("crows feet relationships") was specifically for this reason--readability and ability to translate into good old English. I would suggest you go to http://en.wikipedia.org/wiki/IDEF1X for a brief description of the technique and notation, and more information.

If you have Visio, you can use that to create data models...it has a built-in template for it. If you don't have Visio then you can google some good free data modeling tools. If you are thinking of doing further analysis, having a good-sized markerboard and some dry-erase markers is a good idea.

Hope this helps!

Thanks BitBlt, that made things a bit clearer! :)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.