이 쿼리를 실행했습니다.GROUP BY + SUM where 절
SELECT
grupo,
solicitante,
sum(valuacion) as valuacion,
fecha,
count(*) as cant,
sum(aprobado) as ap,
sum(goe) as goe
FROM
presupuestos
WHERE
ap=0 AND
goe=cant AND
grupo>0 AND
elim=0 AND
sup=0
GROUP BY grupo
ORDER BY fecha_aprobacion ASC
는 MySQL은 반환
#1054 - Unknown column 'ap' in 'where clause'
"AP는"합이며 연속 열이 아니기 때문에.
이에 대한 SQL 해결 방법이 있습니까?
+1을 저주하기 위해 +1. – Zane