Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> comp.databases.theory -> Re: cdt glossary 0.1.0 [Relation]
dawn wrote:
> Mark Johnson wrote:
>
>>[Relation] >>1. A relation is a subset of the set of ordered >>tuples (A1, A2, ... Am) formed by the Cartesian >>cross-product of sets S1 x ... x Sm where each >>An is an element of Sn. >> >>I might say, instead, because I think they logically go closely >>together, and again just as a suggestion, nothing more:
>>Relation - mathematically by a language of sets, a relation is an >>(ordered) array/tuple of elements drawn one each from a set of >>domains, in order, with duplicate domains allowed. This set of >>n-tuples, said to have degree, n, or to be 'n-ary', where the number >>of n-tuples is said to be its, cardinality. The relation is uniquely >>named with regard to other relations. It can both be imagined and >>represented as a 2-D grid, or table.
The "relational model" is, indeed, analogous to the concept of a mathematical relation: a subset of a matrix. The method of matrix construction may include the Cartesian product, but doesn't matter. The Cartesian product is often used because it is defined over many more combinations of operands - potentially infinite, I would guess - than "ordinary" matrix arithmetic.
Unlike matricies (which a mathematic relation is) of mathematics, the order of components in the relational model's non-scalar types - be they tuples in relations or attributes in tuples - is meaningless.
Additionally, the components of tuples and relations are required to be sets: no duplicates allowed. (Taken together, these seem obvious: if a tuple held more than one attribute of the same name, there would be no way to distinguish them if one couldn't refer to "the first" or "the fifth.")
The attributes of tuples are required to be uniquely named. "Back in the day," there might have been some wrangling over distinguishable combinations of attribute "name and type," but such a scheme would have resulted in cumbrous rules: designers would be allowed to change an attribute type only when some other attribute name didn't get in the way. Nonsense.
>
> This definition does not seem better than the one that I think you are
> suggesting be replaced. There are multiple definitions of Relation in
> the glossary. In order for me to understand your point, could you say
> what you think is missing from, or less than clear in, the current
> definitions?
>
>
>>Tuple - also termed an, element, of a relation, it is an unordered set >>of n-attributes,
>>each attribute drawn from a particular dimension or >>domain, as irreducible 'atomic' scalars or strings (though multiples, >>if a multi-valued domain, were once considered),
>>and identified by >>unique name in order to a) express any relationship among any set of >>attributes and b) to allow the tuple to have no particular order. As >>an unordered tuple does not properly correspond with a set relation, >>the relation might be termed, instead, a relationship, which might >>more properly correspond with a table. The tuple can be imagined as a >>vector/array. The tuple can be imagined and represented as a rows in >>the table, its attributes as columns.