Re: Authoritative References
Date: Mon, 4 Oct 2004 06:51:50 -0400
Message-ID: <rcidnRoyEf3HtvzcRVn-gQ_at_comcast.com>
"Marshall Spight" <mspight_at_dnai.com> wrote in message
news:wU58d.172724$D%.67806_at_attbi_s51...
> Cool! So suddenly I'm less clear on what the essential
You probably already know all this, but it's better to make it explicit.
> difference between a relation and a function is. Now
> it seems like it's just two ways of looking at the same
> thing, since both must have a key, and may have more
> than one. Perhaps the differences is simply that of
> saying (n, m) for the relation and n -> m for the
> function. Hmmm.....
Going back to the math, a function has only one value, a relation does not
necessarily. Thus Cosine is a function, but Arc Cosine is a relation.
That is, there is a whole set of angles whose cosine have the same value.
Now let's go back to data. "Find all the employees who live in Nashua, NH."
In the most usual design of personnel data, it's going to look like this:
select employee_id, first_name, last_name
from employees
Now, the fact that we are working with a relation here, rather than a
function, is predicated on the fact that the result is a set, not an
individual employee. There is a unique key here, but it didn't determine
the answer.
If you restrict your self to a functional view, "Where does employee with
id = 12345 live?" is an easy question to phrase.
where city = 'NASHUA' and state = 'NH'