10. Constraints & Indexes
This module combines integrity rules and indexing strategy so you can design schemas that are both safe and fast.
Lessons
Design Matrix
| Need | Feature |
|---|---|
| Unique row identity | PRIMARY KEY |
| Parent-child integrity | FOREIGN KEY |
| Domain/value control | NOT NULL, CHECK, DEFAULT |
| Fast lookups and joins | B-Tree indexes |
What's Next
- Continue to 11. Date & Time Functions