[프로그래머스/SQL] GROUP BY 즐겨찾기가 가장 많은 식당 정보 출력하기
문제 설명 문제 풀이 1 2 3 4 5 6 7 8 SELECT food_type, rest_id, rest_name, favorites FROM rest_info WHERE (food_type, favorites) in ( SELECT food_type, max(favorites) FROM rest_info GROUP BY food_type ) ORDER BY food_type desc; cs