SQL Server约束取值范围


CHECK约束

create table student(
Sno int not null primary key,
age int check(age between 1 and 100)
sex char(2) check(sex in('男bai','女du')
DempNo int)

修改取值范围:https://blog.csdn.net/qq_27494201/article/details/102507259

撤销 CHECK 约束

https://zhidao.baidu.com/question/2052026833620410067.html

添加CHECK约束:https://blog.csdn.net/qq_43551373/article/details/87865739

SQL Server中的约束(六种约束):https://www.cnblogs.com/xiaolinshushu/p/3256110.html

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM