Re: atomic

From: paul c <>
Date: Sat, 03 Nov 2007 15:25:35 GMT
Message-ID: <Pp0Xi.172584$th2.151278_at_pd7urf3no>

David BL wrote:
> On Nov 2, 6:28 am, paul c <> wrote:

>> I'm wondering are there applications where RVA values that are "empty"
>> make sense or are such values just a curious by-product of RVA's?  If
>> the latter, should they be suppressed or somehow prevented?

> In January I started a thread called "RA with MV attributes", in which
> I provided a formal definition of a join operator. It basically takes
> set intersections on the joined attributes. Here is the example I
> used to show it in action, where we are joining on cars...
> r1(Names,Cars)
> bill, car1,car2,car4
> john,fred car3
> r2(Cars,Colours)
> car1,car3,car4 red
> car2 green
> r1 |X| r2 (Names,Cars,Colours)
> bill car1,car4 red
> bill car2 green
> john,fred car3 red
> john,fred green
> Note the suspicious last tuple which has an empty set of cars that are
> green.
> Marshall pointed out that it's rather like a full outer join.
> In that thread I suggested that we could interpret this in FOPL by
> defining a mapping back to conventional predicates with single valued
> attributes, based on taking cross products of the multi-valued
> attributes. Furthermore under that interpretation the above result
> comes back to an inner join!
> Note therefore that the last tuple actually maps to zero predicates.

I've sometimes wondered whether something like this might offer occasional convenience, but as stated I find it hard to reconcile with the "first principles" that I tend to follow (or like to think I follow). Not to say D&D's basic definitions are the only ones that can be used, but I think we'd have to have agreement on how the operators apply. For example, if I understand D&D, r1 |x| r2 above would be empty.

Also I think it is risky in this particular newsgroup to use the term "MV" because there are some posters for whom that stands for something far afield from relational theory so the threads can get quite murky, full of cross-purposes.

To me, it seems inherent in D&D's approach that when we name a relation and its attributes, we are also implicitly defining other relations that have only a subset of those attributes. But the predicates of the implicit relations are existentially qualified, ie., their possible extensions depend on the actual extension of the original relation.   For example, in your r1 |x| r2, it seems to mean among other things that there exist green cars that john and fred own at the same time as there exist no green cars that they could own because the only green car is car2 and they don't own it.

Secondly, if I have a relation with the first three rows of r1 |x| r2 above (header Names, Cars, Colours),

 >    bill              car1,car4     red
 >    bill              car2          green
 >    john,fred         car3          red

and I wish to insert the fact, and only that fact, that john and fred own a green car (if that is what you intend the fourth row to mean), some language might allow me to do that without mentioning the Cars attribute, but I don't think it would be a D&D language because in D&D, "insert" is defined on <OR> and that would mean at minimum we'd need to insert tuples with all possible values of the Cars attribute, eg.,

john,fred                 green
john,fred car1            green
john,fred car1,car2       green

... and so forth.

Personally, I've thought for a couple of years that it might be useful to try to entertain a logical system that supports something akin to what you are talking about but first I think the underlying logical operators would need to be worked out including any precedences that might be required.

When I see the word "space", I usually infer that that the writer is talking about a physical layer. If that's the case here, I still don't think that will wash away my logical questions unless the user interface   includes physical operators, which I think is not a good idea.

I suspect that you might be more technically capable than I am of revising the first principles in a way that might support what you are driving at and I hope you will try. Even if it doesn't result in a logical system, I think the exercise is good.

ps: (I mention D&D because I find their definitions are more precise than Codd's and also because I'm not sure if he ever entertained subsets of headers - from what I've read I think he only talked of header elements and didn't worry about "empty" headers, but I could be wrong.) Received on Sat Nov 03 2007 - 16:25:35 CET

Original text of this message