100% Free Forever
AI-Powered Learning
Industry Expert Content
Certificates & Badges
Learn At Your Own Pace

Database Normalization Cheat Sheet

Database Normalization Cheat Sheet

Normal forms from 1NF through 5NF explained with functional dependency rules and before/after examples for eliminating redundancy.

2 PagesIntermediateFeb 25, 2026

Normal Forms

The progression of normalization levels.

  • 1NF- every column holds atomic values, no repeating groups; rows are unique
  • 2NF- 1NF plus every non-key attribute fully depends on the whole primary key
  • 3NF- 2NF plus no transitive dependencies between non-key attributes
  • BCNF- a stricter 3NF where every determinant must be a candidate key
  • 4NF- eliminates multi-valued dependencies
  • 5NF- eliminates join dependencies not implied by the candidate keys

1NF & 2NF Example

Removing repeating groups and partial dependencies.

sql
-- Unnormalized: repeating groups-- Orders(OrderId, CustomerName, Product1, Product2)-- 1NF: atomic values, one row per productCREATE TABLE OrderItems (  OrderId INT,  Product VARCHAR(100),  PRIMARY KEY (OrderId, Product));-- 2NF: split out data that only depends on part of the composite keyCREATE TABLE Orders (OrderId INT PRIMARY KEY, CustomerName VARCHAR(100));CREATE TABLE OrderItems (  OrderId INT, Product VARCHAR(100), Qty INT,  PRIMARY KEY (OrderId, Product));

3NF Example

Removing a transitive dependency.

sql
-- Before 3NF: transitive dependency (ZipCode -> City)-- Employees(EmpId, ZipCode, City)-- After 3NF: City depends on ZipCode, not directly on EmpIdCREATE TABLE Employees (EmpId INT PRIMARY KEY, ZipCode VARCHAR(10));CREATE TABLE ZipCodes (ZipCode VARCHAR(10) PRIMARY KEY, City VARCHAR(100));

Functional Dependency Terms

Vocabulary used when reasoning about normal forms.

  • Functional dependency- A -> B means A's value determines B's value
  • Candidate key- a minimal set of columns that uniquely identifies a row
  • Determinant- the left-hand side of a functional dependency
  • Partial dependency- a non-key attribute depends on only part of a composite key
  • Transitive dependency- A -> B -> C, where C depends on B which depends on A
  • Denormalization- deliberately reintroducing redundancy to speed up reads
Pro Tip

Normalize for correctness first, usually to 3NF, then selectively denormalize specific hot read paths once real query performance data justifies it — premature denormalization just recreates update anomalies without a proven benefit.

Was this cheat sheet helpful?

Explore Topics

#DatabaseNormalization#DatabaseNormalizationCheatSheet#Database#Intermediate#NormalForms#1NF2NFExample#3NFExample#FunctionalDependencyTerms#Databases#CheatSheet#SkillVeris
Advertisement
Sri Hayavadhana Info-Tech

Professional Web Designing Services

  • Responsive Websites
  • E-commerce Solutions
  • SEO Friendly Design
  • Fast & Secure
  • Support & Maintenance
Get a Free Quote

Share this Cheat Sheet