NOTE: **use Perl;** is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

Why SQL Sucks
More |
Login
| Reply

Stories, comments, journals, and other submissions on use Perl; are Copyright 1998-2006, their respective owners.

## Database in Depth (Score:1)

Maybe I give it a second chance later, but this together with the overall style made me leave it at chapter 3.

## Re:Database in Depth (Score:2)

Yes, tuples can be ordered while a set is not, even though tuples in the relational model are unordered. I believe the distinction here was to ensure that you don't get "Bob, Paris" (assuming "customer, city") and "Paris, Bob" (assuming "city, customer") in the same query and thus getting a result which is effectively duplicated and having negative impacts on subsequent operations. In this sense, what make a "tuple" a "tuple" is not the ordering of the attributes but the names of them. This is actually f

## Re:Database in Depth (Score:1)

The choice of sets reflects the need to avoid the possibility to refer to columns by index, in opinion of a friend of mine.

In math a relation is something much more simple. Given a cartesian product S = S1, S2,

For instance, the relation "less than" in ZxZ is the set of pairs where the first coordinate is less than the second: (1, 2), (5, 100), etc.

In particular, the elements of a relation are tuples, ordered collections of elements of S1, S2,

In my view the idea behind the formalism in Database in Depth is that a relation is something with some plumbing structure to relax the cartesian product to a set of sets, and to be closer to the normal usage (hence the introduction of names, and the separation header body). But as you see that is not a mathematical relation.

Reply to ThisParent