vault backup: 2022-10-24 22:45:59

This commit is contained in:
Jet Hughes 2022-10-24 22:45:59 +13:00
parent 7d5f070ce4
commit 9b1c036922
2 changed files with 32 additions and 1 deletions

View File

@ -6,3 +6,14 @@ tags:
--- ---
# 1 NF
- atomic attributes
- no multivalue/composite/nested relations
# 2 NF
- no nonprime attributes that are partially functionally dependent on primary key
# 3 NF
- remove nonprime attributes that are transitively dependent on primary key
# BCNF

View File

@ -28,9 +28,29 @@ Constraints
- Ref Integrity: Foreign key - Ref Integrity: Foreign key
- Functional Dependencies - Functional Dependencies
- fd: when one value determines another e.g., sid -> sname, {sid, cid} -> grade - fd: when one value determines another e.g., sid -> sname, {sid, cid} -> grade
- armstrong axioms: - armstrong axioms: ![](https://i.imgur.com/3MAOrXD.png)
# Normal Forms # Normal Forms
Help to prevent anomalies (update, delete, insert) by reducing redundancy
e.g.,
```
bad:
Student_Course(sid, sname, address, cid, cname, grade)
good:
Student(sid,sname,address)
Course(cid,cname)
nrolled(sid,cid,grade)
```
done through process of decomposition: breaking down schema into set of schemas while preserving:
- attributes
- dependencies
- lossless joins
Various degrees of normalisatin defined by normal forms:
[Normal Forms](notes/Normal-Forms) [Normal Forms](notes/Normal-Forms)
# SQL # SQL
[SQL](notes/SQL) [SQL](notes/SQL)