I have a column of varchar2(30)
with not null
and check constraint
.
My problem is, I want that column to accept only caps A to caps Z only by using check constraint. How do I do this?
CONSTRAINT check_column_name CHECK (REGEXP_LIKE(column-name, '^[A-Z]+$'));
Here's an sqlfiddle exemplifying it.