Ver originalSELECT "Total General", SUM(if(Estado="ok",1,0)) as ok, SUM(if(Estado="ok",0,1)) as pendiente, COUNT(*) as totalFROM `2008`WHERE Estado IS NOT NULL;
Ver originalSELECT Grupo, SUM(if(Estado="ok",1,0)) as ok, SUM(if(Estado="ok",0,1)) as pendiente, COUNT(*) as totalFROM `2008`WHERE Estado IS NOT NULLGROUP BY Grupo;