Download presentation

Presentation is loading. Please wait.

Published byAidan Frost Modified over 3 years ago

1
Functional dependencies 1

2
2 Outline motivation: update anomalies cause: not expressed constraints on data (FDs) functional dependencies (FDs) definitions examples concepts and terminology (more) advanced theoretical issues (in brief)

3
Functional dependencies 3 Redundancy Student-Modules

4
Functional dependencies 4 Update anomalies - insertion insert the fact that 50012 takes Networks - Introduction; the name of the student and the name of the personal tutor have to be entered as well; this is prone to errors inconsistent data can you identify other kinds of update anomalies on this relation?

5
Functional dependencies 5 Update anomalies - deletion delete the fact that 41002 takes HCI, in the original table; relevant information will be also deleted - about T.A Flo and about HCI.

6
Functional dependencies 6 Update anomalies - modification it is possible to modify an attribute and to bring the relation in an inconsistent state; e.g. it is possible (e.g. by mistake) to modify the value of Database Systems to 1/2cu in just some rows; such situations must be avoided

7
Functional dependencies 7 Cause … of anomalies redundancy … of redundancy constraints on data that are not considered or expressed in the relational model (or, more specifically, on for a particular relation) (some of) these constraints are called Functional Dependencies (FDs) –(others: multiple dependencies, …)

8
Functional dependencies 8 To eliminate the problem express the existing functional dependencies this is done by choosing particular forms for relations - normal forms a relation is in a certain normal form if if it does not contain certain kinds of functional dependencies a relation in a certain normal form eliminates certain kinds of update anomalies a relation that is not in a certain normal form can be transformed (decomposed) into an equivalent set of relations - this process is called normalisation

9
Functional dependencies 9 Functional dependency (FD) R - relation, X and Y - subset of attributes of R X Y iff in every possible legal value of R each X-value has a single Y-value associated time independent (for all time)

10
Functional dependencies 10 Examples S_id S_name S_id P_Tutor S_id (S_id, P_tutor) P_tutor (S_id, S_name, P_tutor) P_tutor Module Val (S_id, Module) Res (S_id, S_name, P_tutor, Module, Val) Res

11
Functional dependencies 11 Concepts FD is a semantic concept determinant / dependent trivial / non-trivial FD left-irreducible yes: (S_id, P_tutor) P_tutor no: (S_id, Module) Res closure irreducible set

12
Functional dependencies 12 Functional diagram S_id City P_tutor S_name S_id Module Res Module

13
Functional dependencies 13 Closure all FDs that can be derived from a given set S notation S+ Armstrongs inference rules if B A then A B if A B then AC BC if A B and B C then A C sound and complete –other rules can be inferred (make the derivation process easier) –A BC iff A B and A C –A B and C D then AC BD

14
Functional dependencies 14 Irreducible set S 1 covers S 2 iff S 2 + S 1 + S is irreducible iff RHS of every FD is non-composite all FDs in S are left-irreducible no FD ca be discarded from S without changing S + a database that enforces S enforces, in fact, S + the irreducible set of S is S iff S - irreducible S + = S + more efficient to work with the irreducible set

15
Functional dependencies 15 Conclusion 2NF, 3NF and BCNF will be defined based on FDs

Similar presentations

OK

Chapter 7 Normalization. Outline Modification anomalies Functional dependencies Major normal forms Relationship independence Practical concerns.

Chapter 7 Normalization. Outline Modification anomalies Functional dependencies Major normal forms Relationship independence Practical concerns.

© 2017 SlidePlayer.com Inc.

All rights reserved.

Ads by Google

Ppt on content development examples Ppt on smps power supply English 8 unit 13 read ppt on iphone Free download ppt on wireless electricity Ppt on sea level rise 2016 Ppt on dubai shopping festival Presentation ppt on global warming Ppt on 2 dimensional figures and 3 dimensional slides Ppt on export marketing management Ppt on time management training