Path: news.easynews.com!core-easynews!newsfeed1.easynews.com!easynews.com!easynews!small1.nntp.aus1.giganews.com!nntp.giganews.com!cyclone1.gnilink.net!wn14feed!wn13feed!worldnet.att.net!204.127.198.203!attbi_feed3!attbi.com!rwcrnsc51.ops.asp.att.net.POSTED!not-for-mail
From: "Marshall Spight" <mspight@dnai.com>
Newsgroups: comp.databases.theory
References: <3ec1cded.0306090420.468aea5e@posting.google.com> <2984440.1055247639@dbforums.com> <3ec1cded.0306102221.2d9b2852@posting.google.com> <8k1Ha.1005196$Zo.227474@sccrnsc03> <3ec1cded.0306152150.22547ef6@posting.google.com>
Subject: Re: functional dependencies
Lines: 58
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
Message-ID: <OZSHa.707981$Si4.829615@rwcrnsc51.ops.asp.att.net>
NNTP-Posting-Host: 12.236.48.146
X-Complaints-To: abuse@attbi.com
X-Trace: rwcrnsc51.ops.asp.att.net 1055914990 12.236.48.146 (Wed, 18 Jun 2003 05:43:10 GMT)
NNTP-Posting-Date: Wed, 18 Jun 2003 05:43:10 GMT
Organization: AT&T Broadband
Date: Wed, 18 Jun 2003 05:43:10 GMT
Xref: core-easynews comp.databases.theory:26863
X-Received-Date: Tue, 17 Jun 2003 22:42:30 MST (news.easynews.com)

"Rohan Hathiwala" <rp_hathiwala@yahoo.com> wrote in message news:3ec1cded.0306152150.22547ef6@posting.google.com...
> Dear Marshall,
>   I did not understand your  example of trivial FD's. Please
> could you explain it more clearly and in tabular form if possible.

Yowsa, I thought I made it as clear as possible. Generally, I'm
pretty good with examples if they're supposed to be "trivial." :-)

I'll make it even simpler.

Here's a table named "T". It has one column named Z typed integer.
It has one row containing the value Z = 1. I'll draw a picture:

T:
|Z|   (column names)
-------------------------
|1|   (rows)

Okay, now we want a trivial functional dependency A -> B. A and
B are sets of columns. In my trivial example, set A is the set containing
exactly one column: column Z. A common way of expressing this is:

    A = {Z}

Set B is the set containing exactly one column: column Z.

    B = {Z}

Note that A and B happen to be the same set, but that is not a problem.

Here, A functionally determines B. Equivalently, B is functionally dependent
on A. That is to say, given a value for the columns listed in set A, you can
obtain exactly one value for each of the set of columns in B. So if I give
you Z=1 as the value of the set of columns specified by A, you can uniquely
identify Z=1 as being the value of the corresponding set of columns
specified by B, which happens in this trivial case to be the same set of
columns.

You *did* ask for trivial, right?  Maybe I could have the same example, but
not mention rows in any way; they're not really necessary.

In general, I find the border cases of such things interesting and informative.
It's enlightening, and simultaneously amusing, to consider (for example)
that every table must have at least one candidate key, and what that means
about having a table with no columns, and how many rows such a table
might have.

As a side bit of advice, I might suggest you de-emphasize your thinking
about the concept of "primary key" since it not something that has any
particular theoretical foundation; it is a thinking shortcut merely. All
candidate keys have the same properties; to declare one of them "primary"
is at best a syntactic convenience.


Marshall



