sql 成绩分组查询
时间:2011-05-05 来源:汪日平
SELECT '60-69 'as a ,count(*)
FROM vb where mark>=60 and mark<=69
UNION ALL SELECT '70-79 'as a,count(*)
FROM vb where mark >=70 and mark<=79
UNION ALL SELECT '80-89 'as a,count(*)
FROM vb where mark >=80 and mark<=89
UNION ALL SELECT '90-99 'as a,count(*)
FROM vb where mark >=90 and mark<=99;
相关阅读 更多 +
排行榜 更多 +