WITH -- 1. 产品基础统计 product_total AS ( SELECT p.product_id, p.unit_price, ROUND(SUM(p.unit_price * o.quantity),2) AS total_sales, SUM(o.quantity) AS total_quantity, ROUND(SUM(p.unit_price * o.quantity) / 12,2) AS avg_monthly_sales FROM products AS p LEFT JOIN orders AS o ON p.product_id = o.product_id...