150 likes | 325 Views
M Taimoor Khan taimoorkhan@ciit-attock.edu.pk. Inference Axioms. Course Objectives. Basic Concepts Tools Database architecture and design Flow of data (DFDs) Mappings (ERDs) Formulating queries (Relational algebra) Implementing Schema Built-in Functions Extracting data
E N D
M Taimoor Khan taimoorkhan@ciit-attock.edu.pk Inference Axioms
Course Objectives • Basic Concepts • Tools • Database architecture and design • Flow of data (DFDs) • Mappings (ERDs) • Formulating queries (Relational algebra) • Implementing Schema • Built-in Functions • Extracting data • Working with Joins • Normalization • Improving performance • Advanced topics
Normalization • Why Normalization • Functional Dependency • Armstrong’s Axioms • First Normal Form (1NF) • Second Normal Form (2NF) • Third Normal Form (3NF) • Boyce - Codd Normal Form (BCNF)
Inference Rules • Called inference axioms or armstrong axioms • These are rules that establish certain FDs from a given set of FDs • These rules are sound
Reflexivity • If B is a subset of A then A B, it also implies that A A always hold, that is stName, stAdr stName Or stName stName
Augmentation • If we have A B then AC BC that is if stId stName then stId, stAdr stName, stAdr
Transitivity • If A B and B C then A C that is If stId prName and prName credits Then stId credits
Additivity or Union • If A B and A C then A BC if empId eName and empId qual Then we can write it as empId eName, qual
Projectivity or Decomposition • If A BC then A B and A C if empId eName, qual Then we can write it as empId eName and empId qual
Pseudotransitivity • If A B and CB D then AC D if stId stName and stName, fName stAdr Then we can write it as stId, fName stAdr
Normalization • Why Normalization • Functional Dependency • Armstrong’s Axioms • First Normal Form (1NF) • Second Normal Form (2NF) • Third Normal Form (3NF) • Boyce - Codd Normal Form (BCNF)
Lab Activity-12 • Sort a Query • Sort multiple columns in a query • Query with two or more tables • Save a query • Create a parameter query
Next Lecture • Normalization