Re: no names allowed, we serve types only

From: Ben Finney <bignose+hates-spam_at_benfinney.id.au>
Date: Sun, 14 Feb 2010 16:41:29 +1100
Message-ID: <87pr48e5me.fsf_at_benfinney.id.au>


Keith H Duggar <duggar_at_alum.mit.edu> writes:

> Of course the conventional definition of a relation's header is a set
> of ordered pairs of "attributes" of the form <A, T> where A is the
> "name" of the attribute (which must be unique within the header) and T
> is a type.

The use of “set of ordered pairs” is telling. Note that the *pairs* are ordered, while the *set* is not; the attributes are unordered within the header.

> I'm wondering, do we really need A? Can we not simplify this header
> notion to just a set of types?

The point of a unique name is to be able to address the attribute.

Without it, there would be no way to distinguish between attributes of identical types in the header.

There would also be no way to change the type of an attribute without also changing all the references to that attribute, even ones where the type is irrelevant.

> So aren't the "ordered pair" and "attribute names" a perhaps sometimes
> convenient yet always unnecessary complication? We can do all we need
> to solely with types and sufficiently rich type systems.

You think we don't need to uniquely address attributes within a header?

-- 
 \         “Alternative explanations are always welcome in science, if |
  `\   they are better and explain more. Alternative explanations that |
_o__) explain nothing are not welcome.” —Victor J. Stenger, 2001-11-05 |
Ben Finney
Received on Sun Feb 14 2010 - 06:41:29 CET

Original text of this message