leetcode 1045 买下所有产品的客户
select customer_id from Customer c left join Product p on c.product_key = p.product_key group by customer_id having count(distinct c.product_key) = (select count(*) from Product)
select customer_id from ( select distinct customer_id, product_key from customer ) t group by customer_id having count(*) = ( select count(product_key) from product )
==
标签:customer,count,product,1045,id,key,买下,leetcode,select From: https://www.cnblogs.com/carlzhang19/p/17391651.html