Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> comp.databases.theory -> Re: table : row : column = entity : occurrence : ?

Re: table : row : column = entity : occurrence : ?

From: David Cressey <david_at_dcressey.com>
Date: Sun, 17 Dec 2000 13:26:19 GMT
Message-ID: <%93%5.129$2X4.10752@petpeeve.ziplink.net>

What "habitat" is depends to some extent on your view of the world.

Here's my view. "Habitat" identifies an occurrence of another entity, the "habitat" entity.
The presence of "habitat" in the flower table is a foreign key, and signifies a relationship between
the lily and a certain habitat.

If however the relationship between habitats and flowers is many-to-many, then the table structure is going to have to change. In the flower table, there should be only one row for the "lily" flower. But if a lily can live in several habitats, then that means several rows.

So we make another table, the "flower_habitat" table, which can have multiple occurrences of "lily",
and multiple occurrences of "marshy" (or whatever the habitat of the lily is. sorry, I don't know), but only one row for the combination of "lily" and "marshy". The flower table contains only attributes of the flower itself, and single valued relationships. (possibly many-to-one, but not many-to-many).

TC wrote in message <91h06t$cm0$1_at_slb0.atl.mindspring.net>...
>I have a question about the terminology used in database design.
>
>Suppose I have a table that stores flower data. One of the records
>represents the lily and one of the fields holds habitat info. If I am not
>mistaken, "flower" is an entity and "lily" is an occurrence of that entity,
>where "entity" and "occurrence" are specific technical terms in the
 database
>world. What, then, is "habitat"? I can think of several words that might
>apply ("property", "attribute", etc.), but if there is an established term
 I
>would like to know it.
>
>Can anyone recommend a book that discusses database design theory at this
>level?
>
>
>-TC
>(cross-posted in comp.databases)
>
>
Received on Sun Dec 17 2000 - 07:26:19 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US