¶
9.12.1.Adding a CHECK Constraint
A CHECK constraint can be added to a table after it has been created and populated providing that none of the tables contents would violate the constraint.
Example9.28.Adding a CHECK constraint to an existing table.
CREATE TABLE test_add_check ( name VARCHAR, age INTEGER ) ; ALTER TABLE test_add_check ADD CONSTRAINT chkage CHECK (age > 18);
See Also: | |
---|---|