Re: constraints in algebra instead of calculus

From: Bob Badour <bbadour_at_pei.sympatico.ca>
Date: Fri, 15 Jun 2007 11:32:49 -0300
Message-ID: <4672a30b$0$4321$9a566e8b_at_news.aliant.net>


Jan Hidders wrote:

> On 15 jun, 04:46, paul c <toledobythe..._at_oohay.ac> wrote:
> 

>>paul c wrote:
>>
>>>paul c wrote:
>>
>>>>...
>>
>>>>3) Use TTM-style GROUP/UNGROUP to test that
>>>>UNGROUP {NK}
>>>> (GROUP ( (A GROUP {NK} as NK ))
>>>>= A
>>>>...
>>
>>>Oops, that last one was completely nuts, can't remember now whatever I
>>>was thinking. Sorry for wasting people's time.
>>
>>>p
>>
>>Marshall, this mis-step has bugged me for days, for no reason that I can
>>explain, except that at one time it all seemed crystal-clear and I'm not
>>sure now whether my memory is bad or whether I was flat-out wrong to
>>think of GROUP et cetera in this way. This might be what I was trying
>>to remember:
>>
>>(Assuming D&D's Tutorial D syntax which I've probably mangled but hoping
>>you get the drift. I've tried to write it slow-motion with a bunch of
>>relvars and assignments, because I don't think I could avoid those
>>without error, even when wide-awake and sober.)
>>
>>R is relvar name, A is candidate key, B is set of all the non-key
>>attributes.
>>
>>1. R1 := R GROUP ( {A} as gA )
>>2. R2 := R1 GROUP ( {B} as gB)
>>3. R3 := R GROUP ( {B} as gB )
>>4. R4 := R3 GROUP ( {A} as gA )
>>5. R5 := R4{gB} <AND> R2
>>6. R6 := UNGROUP ( R5 UNGROUP (gB)) (gA) )
>>7. (constraint) R6 = R
> 
> 
> You can simplify that a bit:
> 
> R1 := (R{B}) GROUP {B} AS gB
> R2 := (R GROUP {B} AS gB){gB}
> constraint: R1=R2
> 
> -- Jan Hidders

Hi Jan,

That constraint looks like a tautology to me. Can you explain how any relation with a B attribute could fail the constraint? Received on Fri Jun 15 2007 - 16:32:49 CEST

Original text of this message