Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> comp.databases.theory -> Re: Requirements for update languages?
lauri.pietarinen_at_atbusiness.com (Lauri Pietarinen) wrote in message news:<e9d83568.0211122359.4cf1d6c6_at_posting.google.com>...
> > Is there a typo in your example -- missing quantities. Also you need a
> > "distinct" keyword whenever referring to sets. Also it seems that the
> > table of integers is unnecessary:
> >
> > SQL>select distinct C1, C2, T1.Q * T2.Q from
> > 2 (select 0 C1, 2 Q from dual) T1,
> > 3 (select 1 C2, 1 Q from dual
> > 4 union
> > 5 select 2 C2, 1 Q from dual) T2
> >
> > C1 C2 T1.Q*T2.Q
> > ---------- ---------- ----------
> > 0 1 2
> > 0 2 2
>
> OK, right. My point being that we have now
> converted the bags into sets, so Date's claim...
>
> "If you do try this exercise, I believe you'll find you're inevitably
> led into using the language of sets, not bags, in order to get around
> the errors and ambiguities."
>
> ...stands true.
OK. Distributions are special cases of relations. That's just an example of primitive reductionalism, when the set theory is seen as the basis of the whole math.
However, not everything is perfect in the relation world. The next exercise would be trying defining aggregate in the *pure* relational terms. A recent posting shows how unnatural defining simple ariphmetics facts in the relational terms is:
My opinion: use distributions instead of sets. Sets are special cases of distributions too!
Some of the earlier discussions "bag vs. set": http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&frame=right&th=e64140c90c9edec6&seekm=61c84197.0204030535.76d68d2a%40posting.google.com#link8 Received on Wed Nov 13 2002 - 12:59:55 CST