si lo coloco asi si me arroja coo valor
1 en cdreprogramados
Código SQL:
Ver originalSELECT s.asistente, SUM( IF( DATE( s.fe_inst_comp ) = '2014-05-26', 1, 0 ) ) AS CDProgramados, SUM( IF( DATE( s.fe_inst_comp ) < '2014-05-26'
AND s.inst != 'si', 1, 0 ) ) AS Bli, SUM( IF( DATE( s.fe_inst_comp ) = '2014-05-26'
AND s.inst = 'si', 1, 0 ) ) AS CDInstalados, (
IF( DATE( r.fe_inst_comp ) = '2014-05-25'
AND r.reprogramacion <> '0'
AND r.reprogramacion IS NOT NULL , 1, 0 )
) AS CDReprogramados
FROM seguimiento s
LEFT JOIN reprogramaciones r ON s.asistente = r.asistente
GROUP BY s.asistente
LIMIT 0 , 30
pero asi no contaria el cmapo no?