Re: OO and relation "impedance mismatch"

From: Gene Wirchenko <genew_at_mail.ocis.net>
Date: Wed, 06 Oct 2004 18:37:04 -0700
Message-ID: <2f39m0hn35ejs117nberlcsah3ckfs916m_at_4ax.com>


Kenneth Downs <firstinit.lastname_at_lastnameplusfam.net> wrote:

[snip]

>The current arbitrary feature for this case, which did not seem worth
>mentioning in that post, is that you can specify a suffix to affix to the
>columns in the child table. So for two foreign keys to the same table one
>is suffixed "_parent" and one suffixed "_child". This makes me really
>uneasy though, I keep thinking "salesperson1", "salesperson2", etc...

     Perfectly legitimate. That is not a 1NF violation. It may be bad design, but that is not necessarily the case.

     There could be
          Departments
          -----------
          ManagerEmpNbr
          SecretaryEmpNbr
          ...

Both columns given could be FKs into an employee table.
     Or
          Games
          -----
          GameDate
          GameLocation
          HomeTeamID
          VisitingTeamID

Sincerely,

Gene Wirchenko

Computerese Irregular Verb Conjugation:

     I have preferences.
     You have biases.
     He/She has prejudices.
Received on Thu Oct 07 2004 - 03:37:04 CEST

Original text of this message