1)select avg(english) from mark;
2)select
cust.Name,cust.Address,cust.Telno,mark.math from cust join mark on cust.Studentno=mark.studentno where cust.Studentno in(11,22,33,44,55);
3)select cust.Name,mark.computer from cust join mark on cust.Studentno=mark.studentno order by mark.computer desc;
4)select cust.Studentno,cust.Name,(mark.math+mark.english+mark.computer) zcj from cust join mark on cust.Studentno=mark.studentno group by cust.Studentno having zcj>240 order by zcj desc;
A、select count(*) from student where name like ‘王%’;
B、select S.id from Student SC join S on S.id=SC.sid join Course on Course.id=SC.cid where Course.name = ‘数学’>Course.name = ‘语文’;
C、select SC.sid,avg(score) from SC join Course on SC.cid=Course.id where avg(score)>90;
Mysql查询语句练习
最新推荐文章于 2023-08-08 21:59:23 发布