为student表的sdept列添加约束,限制该列取值范围为{计算机系,信息管理系,通信工程系}。
举一反三
- 查询不在信息技术系,机电工程系和管理系的学生的信息,所使用的语法命令为( ) A: select * from student where depart not in(’信息技术系’,’机电工程系’,’管理系’) B: select * from student where not depart=’ 信息技术系’ and depart=’ 机电工程系’ and depart=’ 管理系’ C: select * from student where not depart in(”信息技术系”,”机电工程系”,”管理系”) D: select * from student where not depart=”信息技术系”and depart=”机电工程系”and depart=”管理系”
- 查询信息技术系,机电工程系和管理系的学生的信息,所使用的语法命令( ) A: select * from student where depart in(”信息技术系”,”机电工程系”,”管理系”) B: select * from student where depart in(’信息技术系’,’机电工程系’,’管理系’) C: select * from student where depart=”信息技术系”and depart=”机电工程系”and depart=”管理系” D: select * from student where depart=’ 信息技术系’ and depart=’ 机电工程系’ and depart=’ 管理系’
- Check约束可以实现() A: 限制一个表中单个列的取值范围 B: 限制一个表中多个列之间的取值约束 C: 限制不同表之间列的取值约束 D: 为列提供默认值
- 【单选题】针对学生表student(sno,sname,ssex,sage,sdept),其中sno为学号,sname为姓名,ssex为性别,sage为年龄,sdept为系别。查询学生的姓名sname,系别sdept和年龄sage,显示时按系别升序排列,系别相同的再按年龄降序排列。() A. select * from student order by sdept , sage B. select sname, sdept, sage from student order by sdept , sage desc C. select sname, sdept, sage from student order by sdept desc , sage D. select * from student order by sdept desc, sage
- 你所在的本科专业属于信息学院的什么系?() A: 电气工程与自动化系 B: 电子科学与技术系 C: 信息与通信工程系 D: 计算机科学与技术系