Oracle SQL - Table Constraints

Introduction

The type of constraint can be UNIQUE, PRIMARY KEY, FOREIGN KEY, and CHECK.

By default, constraints become active immediately, unless you specify the DISABLE option.

The four types of constraints work as follows:

Constraints Description
UNIQUE prevent duplicate values in a column or a column combination.
PRIMARY KEY implement entity integrity and referential integrity.
FOREIGN KEY implement entity integrity and referential integrity.
CHECK specify any arbitrary condition as a constraint.

Related Topics