Example of Shorthand for a row constraint
Example: Shorthand for a row constraint
ALTER TABLE EXAM_MARK
ADD CONSTRAINT Mark_in_range
CHECK (Mark BETWEEN 0 AND 100);
Actually, it's not quite the only way. The constraint can be included in the column definition for Mark in the CREATE TABLE statement for EXAM_MARK, as shown in Example. A constraint declared as part of a column definition is called a column constraint.