본문 바로가기
DBMS

[프로그래머스 SQL] Lv. 2 성분으로 구분한 아이스크림 총 주문량

by floral1215 2025. 6. 10.
반응형

※ 문제

 

※ 코드

select ingredient_type, sum(total_order) as total_order
from first_half join icecream_info on first_half.flavor = icecream_info.flavor
group by ingredient_type;

 

※ 풀이

flavor를 key로 join하고 group by를 해주면 됩니다.

반응형