select sum(repair_status=1) as to_sure,sum(repair_status=2) as to_done,sum(repair_status=3) as done form table
sum括号里加上引号就不行了,是因为加上引号 是个字段 所以会查询不到。
select sum(repair_status=1) as to_sure,sum(repair_status=2) as to_done,sum(repair_status=3) as done form table
sum括号里加上引号就不行了,是因为加上引号 是个字段 所以会查询不到。