面试让写的sql语句涉及到order by ,group by, having ,like ,limit 等
order by 排序 asc生序,desc降序
group by 分组,having用于分组筛选
like用于模糊匹配查询
limit控制返回的结果条数,以及从第几条返回
select sid,sum(score) as 总分数 where sid>1004 group by sid having 总分数>60 order by 总分数 desc;
select * from student limit 4,10;