Re: terminology q. regarding FK

From: Frank van Bortel <frank.van.bortel_at_gmail.com>
Date: Wed, 12 Nov 2008 19:19:29 +0100
Message-ID: <bcdd8$491b1e32$524b5c40$17918@cache1.tilbu1.nb.home.nl>


mh_at_pixar.com wrote:
> I'm doing some FK analysis of our tables by making a directed
> graph representing FK dependencies and then traversing the
> graph. In my code, I name everything using directed graph
> terminology, but I'd like to have something a bit more
> "user friendly" in the report.
>
> In this scenario:
> create table t1(a varchar2(20));
> alter table t1 add constraint t1_fk foreign key(a) references t2(b);
>
> t1.a must exist in t2.b. So,
>
> t1 is the _______ of t2.
> t2 is the _______ of t1.
>
> Many TIA!
> Mark
>

Long, long ago, I used to use terms like "each and every order contains one or more order lines" "each order line is on an order"

This completely describes the (fully mandatory) relation between orders and order lines.

"each person may drive a car"
"any car may be driven by a person"

This would describe the fully optional relations between persons and cars (in contrast with what American teenagers think)

Generally: when t1 references t2, t1 is called the child of t2. A possible error by Oracle is "no parent record found" when inserting into t1

-- 

Regards,
Frank van Bortel
Received on Wed Nov 12 2008 - 12:19:29 CST

Original text of this message