下列的查询语句哪一项是错误的(选一项)
A: Select * from stumarks where score>=60
B: Select * from (select * from stumarks where score>=60)
C: Select * from (select * from stumarks where score>=60) as temp
D: Select * from (select * from stumarks ) as temp where score>=60
A: Select * from stumarks where score>=60
B: Select * from (select * from stumarks where score>=60)
C: Select * from (select * from stumarks where score>=60) as temp
D: Select * from (select * from stumarks ) as temp where score>=60
举一反三
- 要从SC表中查找缺成绩(SCORE)的学生学号(NO),相应的SQL语句是( )。 A: SELECT NO FROM SC WHERE SCORE = 0 B: SELECT NO FROM SC WHERE SCORE IS 'NULL' C: SELECT NO FROM SC WHERE SCORE = NULL D: SELECT NO FROM SC WHERE SCORE IS NULL
- 成绩表 SCInfo(StId,CNo,Score) 的属性StId表示学号,CNo为课程编号,Score为成绩。从SCInfo表中找出无成绩的元组的SQL语句是( )。 A: SELECT * FROM SCInfo WHERE Score=NULL B: SELECT * FROM SCInfo WHERE Score IS '' C: SELECT * FROM SCInfo WHERE Score ='' D: SELECT * FROM SCInfo WHERE Score IS NULL
- 查询选修了A003课程且成绩在70分以上的学生,最准确的SQL语句是(<br/>)。 A: SELECT<br/>* FROM score WHERE c_no='A003' OR report>70 B: SELECT<br/>* FROM score WHERE c_no='A003' AND report>70 C: SELECT<br/>* FROM score WHERE c_no='A003' D: SELECT<br/>* FROM score WHERE report>70
- 查询同时选修课程号为C1和C5课程的学生的学号,正确的命令是 A: SELECT 学号 FROM score sc WHERE 课程号=’C1’ AND 学号 IN ;(SELECT 学号 FROM score sc WHERE 课程号=’C5’) B: SELECT 学号 FROM score sc WHERE 课程号=’C1’ AND 学号= ;(SELECT 学号 FROM score sc WHERE 课程号=’C5’} C: SELECT 学号 FROM score sc WHERE 课程号=’C1’ AND 课程号=’C5’ D: SELECT 学号 FROM score sc WHERE 课程号=’C1’ OR ’C5’
- 查询选课关系SC(Sno,Cno,Score)表中还没有给定成绩()的课程号()和学号(),下列语句正确的是。() A: SELECT<br/>Sno,Cno<br/>FROM SC WHERE Score IS NULL B: SELECT*<br/>FROM SC WHERE Score =NULL C: SELECT<br/>Sno,Cno<br/>FROM SC D: SELECT<br/>Score FROM SC WHERE Sno,Cno<br/>IS NOT NULL