Oracle CHECK Constraint
In Oracle, CHECK constraint controls the values in the associated column. In other words, CHECK constraints ensures that the value in a certain column satisfy a boolean expression or not.
Oracle CHECK Constraint example
The following Oracle, creates a CHECK constraint on the "Age" column when the "tblCustomer" table is created. The CHECK constraint ensures that the customer's age greater or equal to 18 years:
Oracle CHECK Constraint on ALTER table example
The following Oracle, creates a CHECK constraint on the "Age" column when table already exists into the database:
Oracle DROP a CHECK Constraint example
The following Oracle, dropping CHECK constraint "UC_Customer" from "tblCustomer" table: