group by, compute, LEN, SUBSTRING, TRIM, RTRIM, DATETIME, NULL 관련 함수
USE SQLEx --입사한지12개월이 지난직원들을대상 --185만원이상되는각부서별평균월급 SELECT AVG(salary), depart FROM tblGroup WHERE workMonth > 12 GROUP BY depart having avg(salary) >= 180 ORDER BY AVG(salary) DESC; SELECT * FROM tblGroup; --관리부, 생산부대상 SELECT depart, AVG(salary) FROM tblGroup GROUP BY depart HAVING depart not in('영업부'); --compute -- : 집계함수와사용 SELECT AVG(salary) FROM tblGroup; SELECT * FROM tblGroup compute AVG(s..