Better At Oracle

A collection of tutorials, code and tools to help you get better using Oracle

13 July 2011

All About Referential Integrity

In a series of 3 articles, I explore check constraints, unique indexes and foreign keys including a detailed analysis of their performance, hopefully dispelling some of the myths surrounding Referential Integrity.

Referential Integrity - uniqueness, nulls and checks

This will not be the last application that uses this database, you can be sure of that. Applications come and go, but the data lives on forever. No matter how good and fancy your application, it isn't going to please your users if the INTEGRITY of the data is not 100%.

Referential Integrity - Primary and Foreign Keys

Should you use a Primary Key or just a Unique Index, and what on earth is a Foreign Key?

Referential Integrity - Performance

All these constraints are well and good, but they sure don't come for free. All this checking must cost something in CPU time, but how much?