| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> comp.databases.theory -> Re: erd to db
A small addition and some small corrections.
"Jan Hidders" <hidders_at_uia.ua.ac.be> wrote in message
news:3ca08d65$1_at_news.uia.ac.be...
>
> - Every multivalued attribute of entity or relationship gets its own
table:
> 1. The columns consist of the primary key the table for the
> entity/relationship plus a column with the name of the attribute.
> 2. The primary key of this table consists of all its columns. Note
that
> you may end up with tables and/or columns with the same name, in which
case
> you have to disambiguate them by for example prefixing them with the
entity
> type name or relationship name.
3. The columns of point 1. are indicated as a foreign key to the table for the entity/relationship, if it exists. If it does not exist then the target becomes the table where the relationship is represented by a foreign key. (This happens for certain identifying relationships and one-to-many/one relationships.)
> - Non-identifying one-to-many relationships do *not* get their own table:
This should have been:
- Non-identifying one-to-many relationships without singlevalued attributes
do *not* get their own table:
> - Non-identifying one-to-one relationships do *not* get their own table:
This should have been:
- Non-identifying one-to-one relationships without singlevalued attributes
do *not* get their own table:
Apologies for the inconvenience. As a final remark let me say that you might consider to always map a relationship to a table, but in some cases (esp. identifying relationships) this gives you a redundant database scheme where the relationship-table is simply the projection of the weak-entity table.
![]() |
![]() |