题解 | #列出供应商及其可供产品的数量#
列出供应商及其可供产品的数量
https://www.nowcoder.com/practice/17f22851cf204019b51a36761a3afc79
select
t.vend_id,
count(t1.prod_id) as order_num
from
Vendors t
left join Products t1 using(vend_id)
group by
t.vend_id
order by
t.vend_id
列出供应商及其可供产品的数量
https://www.nowcoder.com/practice/17f22851cf204019b51a36761a3afc79
select
t.vend_id,
count(t1.prod_id) as order_num
from
Vendors t
left join Products t1 using(vend_id)
group by
t.vend_id
order by
t.vend_id
相关推荐