)
举一反三
- 查询学生表中所有数据并保存到永久表STUDENT中:SELECT * FROM 学生表_____ TABLE STUDENT
- 从学生表student查询所有女学生的信息,正确的语句是( )。 A: SELECT B: FROM student where 性别="女"; C: SELECT * FROM student where 性别="女"; D: SELECT ? FROM student where 性别="女"; E: SELECT FROM student where 性别="女";
- 查询学生表中学生人数 Select ()(*) from student
- 对于学生信息表:student(sno,sname,sex,age,dept),要查询所有刘姓学生的信息,正确的语句是 A: SELECT * FROM student WHERE sname LIKE'刘 * ' B: SELECT * FROM student WHERE sname LIKE'刘 $' C: SELECT * FROM student WHERE sname LIKE'刘%' D: SELECT * FROM student WHERE sname LIKE'刘&'
- 请写出查询teaching数据库中student表的满足如下条件的记录的SQL语句:[br][/br] (1)查询student表中所有姓王的学生信息 (2)查询student表中所有名字中不含“王”的所有学生信息 (3)查询stuent表中所有学号为2006020后面跟1,3,4,5,7的学生信息
内容
- 0
学生选课数据库中有如下学生表: 学生表(学号,姓名,专业) (对应的英文表示:student(sno,sname,specialty)) 如果要查询各专业的学生人数,下列查询语句中,正确的是( )。 A: SELECT specialty,count(*) FROM student order by specialty; B: SELECT count(specialty) FROM student order by specialty; C: SELECT specialty,count(*) FROM student group by specialty;
- 1
从学生表student查询所有女学生的信息,正确的语句是( )。 A: SELECT B: FROM student where 性别="女"; C: SELECT * FROM student where 性别="女"; D: SELECT ? FROM student where 性别="女"; E: SELECT FROM student where 性别="女";
- 2
查询姓“李”的学生的所有信息 A: select * from student where sname like ‘#李%’ B: select * from student where sname like ‘%李#’ C: select * from student where sname like “%李%” D: select * from student where sname like ‘%李%
- 3
查询所有非计算机系学生的信息,不正确的SQL语句是:( ) A: SELECT * FROM Student WHERE Sdept != 'CS'; B: SELECT * FROM Student WHERE NOT Sdept = 'CS'; C: SELECT * FROM Student WHERE Sdept IN ('MA', 'IS'); D: SELECT * FROM Student WHERE NOT Sdept IN ('CS');
- 4
在所有学生中查询比计算机系学生平均年龄大的学生姓名,可以使用的查询语句是: A: SELECT Sname FROM Student WHERE Sage > ( SELECT AVG(Sage) FROM Student ); WHERE Sdept = 'CS' B: SELECT Sname FROM Student WHERE Sage > AVG( SELECT Sage FROM Student WHERE Sdept = 'CS' ); C: SELECT Sname FROM Student WHERE Sage > ( SELECT AVG(Sage) FROM Student WHERE Sdept = 'CS' ); D: SELECT Sname FROM Student WHERE AVG(Sage) > ( SELECT Sage FROM Student WHERE Sdept = 'CS' );