certificate在数据库的值有可能是c1,c2,c3,c4 还有可能是c1,c2等等,"sum(decode(a.certificate,'c1',1,0)) as certificate_c1, "
如何统计出每种证书的所有数量?
SELECT certificate,COUNT(certificate) FROM a GROUP BY certificate
select sum( case when LOCATE(a.certificate, ‘c1‘) > 0 then 1 else 0 ) as c1 from