二十一、唯一约束

唯一性约束(unique),它可以使某个字段的值不能重复。 如:email不能重复 以上插入了重复的email,所以出现了“违反唯一约束错误”,所以unique起作用了 同样可以为多个字段做约束 drop table if exists t_student; create table t_student( student_id int(10), student_name varchar(20) n
相关文章
相关标签/搜索