Oracle 检查约束check

Posted 学亮编程手记

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Oracle 检查约束check相关的知识,希望对你有一定的参考价值。

--检查约束
create table test1(
       id number(10) primary key,
       email varchar2(10) check (email like %@%)
)
drop table test1
insert into test1 values(1,[email protected]);
select * from test1

create table test2(
       id number primary key,
       gender varchar2(4) check(gender in(,))
)
drop table test2
select * from test2
insert into test2 values(1,)

 

以上是关于Oracle 检查约束check的主要内容,如果未能解决你的问题,请参考以下文章