查询学生的学号,姓名,选修课程号和课程成绩 A: select sid,sname,cid,grade from student,sc where student.sid=sc.sid B: select * from student,sc where student.sid=sc.sid C: select sid,sname,cid,cname from student,course D: select sid,sname,cid,cname from student,sc
查询学生的学号,姓名,选修课程号和课程成绩 A: select sid,sname,cid,grade from student,sc where student.sid=sc.sid B: select * from student,sc where student.sid=sc.sid C: select sid,sname,cid,cname from student,course D: select sid,sname,cid,cname from student,sc
【填空题】阅读程序写结果 public class Student { private static int sid = 0; private String name; int id; Student(String name) { this.name = name; id = sid++; } public void info() { System.out.println("My name is "+name+" No."+id); } public static void infoSta() { System.out.println(sid); } public static void main(String arg[]) { Student.sid = 100; Student st1 = new Student("huahua"); st1.sid = 2000; Student st2 = new Student("meimei"); st1.info(); st2.info(); } }
【填空题】阅读程序写结果 public class Student { private static int sid = 0; private String name; int id; Student(String name) { this.name = name; id = sid++; } public void info() { System.out.println("My name is "+name+" No."+id); } public static void infoSta() { System.out.println(sid); } public static void main(String arg[]) { Student.sid = 100; Student st1 = new Student("huahua"); st1.sid = 2000; Student st2 = new Student("meimei"); st1.info(); st2.info(); } }
查询成绩在60分以上的学生的信息及其选课的课程号和成绩 A: select student.*,cid,grade from student,sc where student.sid=sc.sid and grade>=60 B: select * from student,sc where student.sid=sc.sid where grade>=60 C: select * from student,sc where student.sid=sc.sid where student.sid=sc.sid D: select * from student,course where grade>=60
查询成绩在60分以上的学生的信息及其选课的课程号和成绩 A: select student.*,cid,grade from student,sc where student.sid=sc.sid and grade>=60 B: select * from student,sc where student.sid=sc.sid where grade>=60 C: select * from student,sc where student.sid=sc.sid where student.sid=sc.sid D: select * from student,course where grade>=60
学生表student中包含字段:学生编号sid(主键),学生姓名sname。成绩表score包含字段:课程编号cid,学生编号sid(外键),学生成绩degree;其中学生表包含10行数据,成绩表包含6行记录(且sid列没有重复值),那么执行SQL语句:select * from student left outer join score on student.sid=score.sid,将返回()条记录
学生表student中包含字段:学生编号sid(主键),学生姓名sname。成绩表score包含字段:课程编号cid,学生编号sid(外键),学生成绩degree;其中学生表包含10行数据,成绩表包含6行记录(且sid列没有重复值),那么执行SQL语句:select * from student left outer join score on student.sid=score.sid,将返回()条记录
修改student表中学号为2015001的学生的姓名为“张三” A: update student set sname=’ 张三’ where sid=’2015001’ B: alter table student alter sname=’ 张三’ where sid=’2015001 C: update student set sname=”张三” where sid=’2015001’ D: update student set sname=张三 where sid=’2015001’
修改student表中学号为2015001的学生的姓名为“张三” A: update student set sname=’ 张三’ where sid=’2015001’ B: alter table student alter sname=’ 张三’ where sid=’2015001 C: update student set sname=”张三” where sid=’2015001’ D: update student set sname=张三 where sid=’2015001’
修改student表中学号为2015001的学生的姓名为“张三”,语句是()。 A: update student set sname=’ 张三’ where sid=’2015001’ B: update student set sname=张三 where sid=’2015001’ C: update student set sname=”张三” where sid=’2015001’ D: alter table student alter sname=’ 张三’ where sid=’2015001’
修改student表中学号为2015001的学生的姓名为“张三”,语句是()。 A: update student set sname=’ 张三’ where sid=’2015001’ B: update student set sname=张三 where sid=’2015001’ C: update student set sname=”张三” where sid=’2015001’ D: alter table student alter sname=’ 张三’ where sid=’2015001’
在学生关系student(sid,sname……)中,student的属性分别表示学号和姓名,若要查询学号为19170201的学生姓名,下列SQL语句正确的是( )。Ⅰ.SELECT sname FROM student WHERE sid LIKE '19170201'Ⅱ.SELECT sname FROM student WHERE sid LIKE= '19170201'Ⅲ.SELECT sname FROM student WHERE sid='19170201' A: Ⅰ、Ⅱ B: Ⅰ、Ⅲ C: Ⅱ、Ⅲ D: Ⅰ、Ⅱ、Ⅲ
在学生关系student(sid,sname……)中,student的属性分别表示学号和姓名,若要查询学号为19170201的学生姓名,下列SQL语句正确的是( )。Ⅰ.SELECT sname FROM student WHERE sid LIKE '19170201'Ⅱ.SELECT sname FROM student WHERE sid LIKE= '19170201'Ⅲ.SELECT sname FROM student WHERE sid='19170201' A: Ⅰ、Ⅱ B: Ⅰ、Ⅲ C: Ⅱ、Ⅲ D: Ⅰ、Ⅱ、Ⅲ
按照学号进行分组,统计学生的平均成绩() A: select sid, avg(grade) from student group by cid B: select sid, avg(grade) from student group by sid C: select sid, avg(grade) from sc group by sid D: select sid, avg(grade) from sc group by cid
按照学号进行分组,统计学生的平均成绩() A: select sid, avg(grade) from student group by cid B: select sid, avg(grade) from student group by sid C: select sid, avg(grade) from sc group by sid D: select sid, avg(grade) from sc group by cid
删除student表中的sid列。
删除student表中的sid列。
按照学号进行分组,统计学生的平均成绩,且平均分按降序排列 A: select sid, avg(grade) from sc group by sid order by avg(grade) desc B: select sid, avg(grade) from sc group by cid order by avg(grade) desc C: select sid, avg(grade) from student group by sid order by avg(grade) desc D: select sid, avg(grade) from student group by cid order by avg(grade)
按照学号进行分组,统计学生的平均成绩,且平均分按降序排列 A: select sid, avg(grade) from sc group by sid order by avg(grade) desc B: select sid, avg(grade) from sc group by cid order by avg(grade) desc C: select sid, avg(grade) from student group by sid order by avg(grade) desc D: select sid, avg(grade) from student group by cid order by avg(grade)