查询选修了课程号为“C2”的学生中成绩最高的学生的学号,正确的SELECT语句是()。 A: SELECTS B: FROMSC WHEREC C: ='C2'ANDGRADE>=ALL D: (SELECTGRADE FROMSC WHEREC E: ='C2') F: SELECTS G: FROMSC WHEREC H: ='C2'ANDGRADEIN I: (SELECTMAX(GRADE) FROMSC WHEREC J: ='C2') K: SELECTS L: FROMSC WHEREC M: ='C2'ANDGRADE= N: (SELECTMAX(GRADE) FROMSC WHEREC O: ='C2') P: SELECTS Q: FROMSC WHEREC R: ='C2'ANDGRADE>=ANY S: (SELECTGRADE FROMSC WHEREC T: ='C2')
查询选修了课程号为“C2”的学生中成绩最高的学生的学号,正确的SELECT语句是()。 A: SELECTS B: FROMSC WHEREC C: ='C2'ANDGRADE>=ALL D: (SELECTGRADE FROMSC WHEREC E: ='C2') F: SELECTS G: FROMSC WHEREC H: ='C2'ANDGRADEIN I: (SELECTMAX(GRADE) FROMSC WHEREC J: ='C2') K: SELECTS L: FROMSC WHEREC M: ='C2'ANDGRADE= N: (SELECTMAX(GRADE) FROMSC WHEREC O: ='C2') P: SELECTS Q: FROMSC WHEREC R: ='C2'ANDGRADE>=ANY S: (SELECTGRADE FROMSC WHEREC T: ='C2')
基于教材上的选课表SC,使用嵌套查询查找所有超过所选课程平均分的学生选课记录,正确的SQL语句是________。 A: SELECTSno, Cno, Grade FROMSC SC1WHERE Grade>;(SELECT AVG(Grade) FROMSC SC2); B: SELECTSno, Cno, Grade FROMSC SC1WHERE Grade>;(SELECT AVG(Grade) FROMSC SC2 WHERE SC2.Cno=SC1.Cno); C: SELECTSno, Cno, Grade FROMSC SC1WHERE Grade>;(SELECT AVG(Grade) FROMSC SC2 GROUP BY SC2.Cno); D: SELECTSno, Cno, Grade FROMSC SC1WHERE AVG(Grade)>;(SELECT Grade FROMSC SC2 WHERE SC2.Cno=SC1.Cno);
基于教材上的选课表SC,使用嵌套查询查找所有超过所选课程平均分的学生选课记录,正确的SQL语句是________。 A: SELECTSno, Cno, Grade FROMSC SC1WHERE Grade>;(SELECT AVG(Grade) FROMSC SC2); B: SELECTSno, Cno, Grade FROMSC SC1WHERE Grade>;(SELECT AVG(Grade) FROMSC SC2 WHERE SC2.Cno=SC1.Cno); C: SELECTSno, Cno, Grade FROMSC SC1WHERE Grade>;(SELECT AVG(Grade) FROMSC SC2 GROUP BY SC2.Cno); D: SELECTSno, Cno, Grade FROMSC SC1WHERE AVG(Grade)>;(SELECT Grade FROMSC SC2 WHERE SC2.Cno=SC1.Cno);
“SELECTCOUNT(DISTINCTSno)FROMSC”语句用于统计学生的总人数。()
“SELECTCOUNT(DISTINCTSno)FROMSC”语句用于统计学生的总人数。()
查询选了课的学生人数:SELECTCOUNT(SNO)FROMSC;
查询选了课的学生人数:SELECTCOUNT(SNO)FROMSC;
有表student(sno,sname,ssex,sbirth,sdept);表course(cno,cname);表sc(sno,cno,degree),查询选修了课程的学号,使用的FROM子句正确的是:() A: FROMsc B: FROMstudent C: FROMcourse D: FROMsno
有表student(sno,sname,ssex,sbirth,sdept);表course(cno,cname);表sc(sno,cno,degree),查询选修了课程的学号,使用的FROM子句正确的是:() A: FROMsc B: FROMstudent C: FROMcourse D: FROMsno
课程表C和学生选课表SC,它们的结构如下: A: S(S B: ,SN,SEX,AGE,DEPT) C: (C D: ,CN) E: C(S F: ,C G: ,GRADE) H: 中:S I: 为学号,SN为姓名,SEX为性别,AGE为年龄,DEPT为系别,C J: 为课程号,CN为课程名,GRADE为成绩 K: 、检索学生姓名及其所选修课程的课程号和成绩,正确的SELECT语句是()。 L: SELECTS.SN,SC.C M: ,SGRADE N: FROMS WHERES.S O: =SS P: ; Q: SELECTS.SN,SC.C R: ,SGRADE S: FROMSC WHERES.S T: =SGRADE; U: SELECTS.SN,SC.C V: ,SGRADE W: FROMS,SC WHERES.S X: =SS Y: ; Z: SELECTS.SN,SC.C [: ,SGRADE FROMS,SC;
课程表C和学生选课表SC,它们的结构如下: A: S(S B: ,SN,SEX,AGE,DEPT) C: (C D: ,CN) E: C(S F: ,C G: ,GRADE) H: 中:S I: 为学号,SN为姓名,SEX为性别,AGE为年龄,DEPT为系别,C J: 为课程号,CN为课程名,GRADE为成绩 K: 、检索学生姓名及其所选修课程的课程号和成绩,正确的SELECT语句是()。 L: SELECTS.SN,SC.C M: ,SGRADE N: FROMS WHERES.S O: =SS P: ; Q: SELECTS.SN,SC.C R: ,SGRADE S: FROMSC WHERES.S T: =SGRADE; U: SELECTS.SN,SC.C V: ,SGRADE W: FROMS,SC WHERES.S X: =SS Y: ; Z: SELECTS.SN,SC.C [: ,SGRADE FROMS,SC;