Re: Concurrency in an RDB
From: paul c <toledobythesea_at_oohay.ac>
Date: Sat, 23 Dec 2006 15:48:53 GMT
Message-ID: <Fdcjh.513933$5R2.243772_at_pd7urf3no>
>
>
> It states something different. Whether it is useful depends on the
> predicate of the relation. I had not noticed when I created the example
> that I associate a3 with {} in each tuple. Nothing says that is
> necessary. I could just as easily created the example as:
>
> R = { { a1, { a2, { a3, {} } } } /* a=a1, b={ a2, { a3, {} } */
> , { a4, { a3, {} } } /* a=a4, b={ a3, {} } */
> , { a5, { a3, { a2, {} } } } /* a=a5, b={ a3, { a2, {} } */
> }
>
> R1 = R{a} = { { a1 }, { a4 }, { a5 } }
> R2 = R{b} = { { a2, { a3, {} } }, { a3, {} }, { a3, { a2 {} } } }
>
>
> Or is it redundant?
>
> It is not redundant.
>
>
> One way I look at
>
>
>
> As I clarified above, nothing says a3 always stands in the same relation
> to {}. That was merely incidental in my example.
>
>
>
>
> Why bother? Only bother if it is or becomes true.
>
>
>
>
> I think my original example misled you.
Date: Sat, 23 Dec 2006 15:48:53 GMT
Message-ID: <Fdcjh.513933$5R2.243772_at_pd7urf3no>
Bob Badour wrote:
> paul c wrote:
>
>> Bob Badour wrote: >> ... >> >>> What I am saying is: When you project onto A, the data type of B is >>> mostly** irrelevant. Likewise, when you project onto B, the data type >>> of A is mostly irrelevant. >>> >>> The fact that you have a recursive data type definition has no effect >>> on project or join or restrict or union or intersect or difference >>> etc. The values identified as B are simply values. >>> >>> Assuming: >>> >>> A = { a1, a2, a3, a4, a5 } >>> B = { {a,b} | a in A and b in B } >>> >>> Given relation R{a in A,b in B}: /* Using C-style comments */ >>> >>> R = { { a1, { a2, { a3, {} } } } /* a=a1, b={ a2, { a3, {} } */ >>> , { a4, { a3, {} } } /* a=a4, b={ a3, {} } */ >>> , { a5, { a2, { a3, {} } } } /* a=a5, b={ a2, { a3, {} } */ >>> } >>> >>> >>> Project R onto R1=R{A}: >>> >>> R1 = { { a1 }, { a4 }, { a5 } } >>> >>> Project R onto R2=R{B}: >>> >>> R2 = { { a2, { a3, {} } }, { a3, {} } } >>> >>> >>> ** I say "mostly" irrelevant because the predicate for the projected >>> relation still makes reference to B in the sense of "A where exists >>> some B". >> >> >> >> Suppose (as in the example): >> >> R = { { a1, { a2, { a3, {} } } } /* a=a1, b={ a2, { a3, {} } */ >> , { a4, { a3, {} } } /* a=a4, b={ a3, {} } */ >> , { a5, { a2, { a3, {} } } } /* a=a5, b={ a2, { a3, {} } */ >> } >> >> and that we are able to insert { a3, {} } (somehow) giving: >> >> R = { { a1, { a2, { a3, {} } } } /* a=a1, b={ a2, { a3, {} } */ >> , { a4, { a3, {} } } /* a=a4, b={ a3, {} } */ >> , { a5, { a2, { a3, {} } } } /* a=a5, b={ a2, { a3, {} } */ >> , { a3, { } } >> } >> >> Does this state anything useful?
>
>
> It states something different. Whether it is useful depends on the
> predicate of the relation. I had not noticed when I created the example
> that I associate a3 with {} in each tuple. Nothing says that is
> necessary. I could just as easily created the example as:
>
> R = { { a1, { a2, { a3, {} } } } /* a=a1, b={ a2, { a3, {} } */
> , { a4, { a3, {} } } /* a=a4, b={ a3, {} } */
> , { a5, { a3, { a2, {} } } } /* a=a5, b={ a3, { a2, {} } */
> }
>
> R1 = R{a} = { { a1 }, { a4 }, { a5 } }
> R2 = R{b} = { { a2, { a3, {} } }, { a3, {} }, { a3, { a2 {} } } }
>
>
> Or is it redundant?
>
> It is not redundant.
>
>
> One way I look at
>
>> this is to imagine that the value a3 stands in the same relation to {} >> as a2 stands to { a3, {} } or put another way a3 has the same relation >> to {} as a2 has to { a3, {} }. But in the tuple >> >> { { a1, { a2, { a3, {} } } } /* a=a1, b={ a2, { a3, {} } */ >> >> is it not already implicit that a3 stands in that same relation to {}?
>
>
> As I clarified above, nothing says a3 always stands in the same relation
> to {}. That was merely incidental in my example.
>
>
>> Eg., why bother with the fourth tuple? If I go without the inserted >> (fourth) tuple, then by itself, it must be false, ie., it must be true >> in the logical complement of R. So the first tuple implies that a3 >> has relation R to {} but the complement or R says it doesn't, which >> looks like a contradiction to me!
>
>
> Why bother? Only bother if it is or becomes true.
>
>
>> Maybe this is nonsense, but I'd to know why!
>
>
> I think my original example misled you.
Yes, can't argue with any of that. I suppose whether a predicate is
nonsensical depends on the application. In a genealogical app, say,
maybe one could choose to say the parent relation allows a2 to be a
parent of a parent a3 of an empty family
{a3, {} }
at the same time as a5 could be the parent of the parent a3 of a
non-empty family
{ a3, { a2, {} } } !
p Received on Sat Dec 23 2006 - 16:48:53 CET