Re: Constraints and Functional Dependencies

From: Marshall <>
Date: 24 Feb 2007 08:13:21 -0800
Message-ID: <>

On Feb 24, 6:41 am, paul c <> wrote:
> Marshall wrote:
> > ...
> > With such a system, a relation R with attribute a (which I will
> > write as R(a)) having a as a foreign key into S(b) is expressed
> > as follows:
> > forall R(a): exists S(b): a = b
> > So we can express foreign keys this way.
> > ...
> I presume that if S had other attributes besides b, this definition
> would mean that b doesn't need to be a so-called primary key? (That
> would be okay with me.)

Yeah. You'd need another constraint to express that, and I don't think it would be possible to express the constraint that foreign keys must reference primary keys, because that would be a second order formula: it quantifies over formulas.

The system itself might have an implementation constraint, but off the top of my head I don't see why it would need one.

Of course, in practice I don't think one is likely to want to reference
anything that isn't a key.

Marshall Received on Sat Feb 24 2007 - 17:13:21 CET

Original text of this message