If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > General > Database Concepts & Design > Generalization Hierarchy help pls

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 04-28-04, 06:39
waipeng waipeng is offline
Registered User
 
Join Date: Apr 2004
Location: KL
Posts: 1
Generalization Hierarchy help pls

Hi,

I'm a student currently working on my final year project. I came accross this topic of Generalization Hierarchy at http://www.utexas.edu/its/windows/da...erarchies.html but the article was not very detailed.

I need to be sure if the entity 'artefact', which could be anything ranging from paintings to furniture, can suitably used here. If so, how can I apply that into relational databases i.e: steps to make generalized tables (if that's what they can be called)

Pls point to some source of info too - like, where do I begin?

Thanks

Last edited by waipeng; 04-28-04 at 07:05.
Reply With Quote
  #2 (permalink)  
Old 05-06-04, 19:05
johnson2 johnson2 is offline
Registered User
 
Join Date: May 2004
Posts: 5
I think the answer to your question, if a generlaization hierarchy could be used for storing information about artefacts, depends on what information you want to store. To answer this accurately someone would need to know the requirements of your system including what attributes of an artefact you intend to record about each instance of an artefact.

For example, if for each artefact you only want to track it's unique name and date of creation you would only need a single entity with these two attributes.

Alternately, if you wanted to track each artefacts unique name and date of creation and then other information specific to the type of artefact, a generalization hierarchy may be your best choice. For example, for artefacts that are paintings you might want to track the artist and type of paint used, while for furniture you would want to track the material used and style. To extend this further, with this method you could even track different attributes of sofas and chairs (as subtypes of furniture). Where for a sofa you would track the size and for a chair, maybe the number of legs.

To create tables for the generalization hierarchy described above:

artefacts
---------
name (PK)
creationDate

paintings
---------
name (PK) (FK references artefacts.name)
artist
paintType

furniture
--------
name (PK) (FK references artefacts.name)
material
style

sofas
-----
name (PK) (FK references furniture.name)
size

chairs
------
name (PK) (FK references furniture.name)
numberOfLegs
Reply With Quote
  #3 (permalink)  
Old 05-21-04, 21:15
certus certus is offline
Registered User
 
Join Date: Dec 2003
Location: Canada
Posts: 710
Below is an illustration of the model.

Note the inclusion of discriminators, artefact_type and furniture_type.
Attached Images
File Type: gif 1 generalization.GIF (5.1 KB, 410 views)
__________________
visit: relationary
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On