https://leetcode.com/problems/warehouse-manager/
Account Login - LeetCode
Level up your coding skills and quickly land a job. This is the best place to expand your knowledge and get prepared for your next interview.
leetcode.com
이게 될까 하고 돌렸는데 되네..
select a.name as warehouse_name, sum(a.units*b.volume) as volume
from Warehouse as a
left join (select *, Width*Length*Height as volume from Products) as b
on a.product_id = b.product_id
group by a.name
728x90
반응형
'자료구조 알고리즘 > 코딩테스트' 카테고리의 다른 글
1623. All Valid Triplets That Can Represent a Country (0) | 2022.06.18 |
---|---|
1587. Bank Account Summary II (0) | 2022.06.18 |
198. House Robber (0) | 2022.06.11 |
61. Rotate List (0) | 2022.06.09 |
1741. Find Total Time Spent by Each Employee (0) | 2022.06.09 |