题解 | 电商平台想要查询出每个商品在 2024 年上半年(1 月至 6 月)的总销售额
电商平台想要查询出每个商品在 2024 年上半年(1 月至 6 月)的总销售额
https://www.nowcoder.com/practice/e190c019dabe4622ae719cca64437a47
select p.product_id,product_name,sum(price*quantity) total_sales from products_underline p join sales_underline s on p.product_id = s.product_id where sale_month between '2024-01' and '2024-06' group by p.product_id order by p.product_id

查看13道真题和解析
叮咚买菜工作强度 250人发布