SELECT
order_table.increment_id, item_table.created_at, item_table.sku, item_table.price, order_table.`status`
FROM sales_flat_order_item AS item_table
LEFT JOIN sales_flat_order AS order_table ON order_table.entity_id=item_table.order_id
WHERE item_table.created_at <= '2015-08-01' and order_table.`status`='complete'
GROUP BY sku
Magento查询历史完成订单的产品销售价格
最新推荐文章于 2021-01-19 01:33:35 发布
本文介绍了一个SQL查询案例,用于从数据库中筛选出指定日期前已完成状态的订单,并按SKU进行分组汇总。
1413

被折叠的 条评论
为什么被折叠?



