资源描述:
《数据库系统概念全套配套课件PPT appB.ppt》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、AppendixB:AdvancedRelationalDatabaseDesignAppendixB:AdvancedRelationalDatabaseDesignReasoningwithMVDsHighernormalformsJoindependenciesandPJNFDKNFTheoryofMultivaluedDependenciesLetDdenoteasetoffunctionalandmultivalueddependencies.TheclosureD+ofDisthesetofallfunctionalandm
2、ultivalueddependencieslogicallyimpliedbyD.Soundandcompleteinferencerulesforfunctionalandmultivalueddependencies:1.Reflexivityrule.Ifisasetofattributesand,thenholds.2.Augmentationrule.Ifholdsandisasetofattributes,thenholds.3.Transitivityrule.Ifholdsand
3、holds,thenholds.TheoryofMultivaluedDependencies(Cont.)4.Complementationrule.Ifholds,thenR––holds.5.Multivaluedaugmentationrule.IfholdsandRand,thenholds.6.Multivaluedtransitivityrule.Ifholdsandholds,then–holds.7.Replicationrule.Ifholds,then
4、.8.Coalescencerule.IfholdsandandthereisasuchthatRand=and,thenholds.SimplificationoftheComputationofD+WecansimplifythecomputationoftheclosureofDbyusingthefollowingrules(provedusingrules1-8).Multivaluedunionrule.Ifholdsandholds,thenholds.Intersectio
5、nrule.Ifholdsandholds,thenholds.Differencerule.IfIfholdsandholds,then–holdsand–holds.ExampleR=(A,B,C,G,H,I)D={ABBHICGH}SomemembersofD+:ACGHI.SinceAB,thecomplementationrule(4)impliesthatAR–B–A.SinceR–B–A=CGHI,soACGHI.AHI.SinceABandBHI,themultivaluedtr
6、ansitivityrule(6)impliesthatBHI–B.SinceHI–B=HI,AHI.Example(Cont.)SomemembersofD+(cont.):BH.Applythecoalescencerule(8);BHIholds.SinceHHIandCGHandCGHI=Ø,thecoalescenceruleissatisfiedwithbeingB,beingHI,beingCG,andbeingH.WeconcludethatBH.ACG.ACGHIandAHI.Bythedifferen
7、cerule,ACGHI–HI.SinceCGHI–HI=CG,ACG.NormalizationUsingJoinDependenciesJoindependenciesconstrainthesetoflegalrelationsoveraschemaRtothoserelationsforwhichagivendecompositionisalossless-joindecomposition.LetRbearelationschemaandR1,R2,...,RnbeadecompositionofR.IfR=R1R2….
8、Rn,wesaythatarelationr(R)satisfiesthejoindependency*(R1,R2,...,Rn)if:r=R1(r)⋈R2(r)⋈……⋈Rn(r)Ajoindepe