非空约束not null 约束的字段不能为null

    1. create table t_vip(
    2. id int,
    3. name varchar(255) not null
    4. );
    5. insert into t_vip(id,name) values(1,'张三');
    6. insert into t_vip(id,name) values (2,'李四');
    7. insert into t_vip(id,name) values (3); #报错,设有not null 的字段不能为空,必须插入数据

    not null只有列级约束,没有表级约束