Introduction to Constraints and Sequences
PRIMARY KEY, FOREIGN KEY, UNIQUE, CHECK and DEFAULT constraints for data integrity, and sequence objects for number generation.
- 3 lessons
- Module quiz
Constraints let the database enforce rules for every application that writes to it, and sequences generate numbers with more control than IDENTITY columns.
What the exam expects
Questions test PRIMARY KEY, FOREIGN KEY and referential actions, UNIQUE constraints and NULL handling, CHECK and DEFAULT constraints, and when a SEQUENCE is better than IDENTITY.
How this module is organized
Primary Key and Foreign Key Constraints covers keys and referential integrity. UNIQUE, CHECK and DEFAULT Constraints covers the other constraints. Generating Numbers with Sequences covers sequences.