1111数字代表什么意思:SQL查询分析器里统计及格百分比的语句

来源:百度文库 编辑:神马品牌网 时间:2024/05/04 08:56:02
SQL中有张成绩表,有学生基本学号(id),姓名(name),性别(Sex),班级(class)和成绩(cj)这些信息,求在查询分析器里统计及格百分比的语句。
是select str(100*sum(case when cj<60 then 0 else 1 end)/count(id))+'%' from student

select 100*sum(case when cj<60 then 0 else 1 end)/count(id)+'%' from table1