Re: Requirements for update languages?

From: Mikito Harakiri <mikharakiri_at_yahoo.com>
Date: 13 Nov 2002 10:59:55 -0800
Message-ID: <bdf69bdf.0211131059.aa2cd40_at_posting.google.com>


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:

http://groups.google.com/groups?q=sum+group:comp.databases.theory+author:pbrazier%40cosmos-uk.co.uk&hl=en&lr=&ie=UTF-8&as_drrb=b&as_mind=12&as_minm=5&as_miny=2002&as_maxd=28&as_maxm=12&as_maxy=2002&selm=51d64140.0210080104.f79cbee%40posting.google.com&rnum=1

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 - 19:59:55 CET

Original text of this message