【发布时间】:2018-01-01 15:00:17
【问题描述】:
我目前在使用 WooCommerce 网站时遇到了一些问题。有数以千计的旧订单停留在“处理中”状态。 这些订单已收到付款,产品已发货。
我想将这些订单标记为已完成,而不发送已完成的订单电子邮件。我想使用以下 SQL 查询来实现这一点。
update wp_posts set post_status = 'wc-completed' where post_type = 'shop_order' and post_status ='wc-processing' ;
我还需要更改其他表吗?或者这样可以吗?
谢谢
编辑: 上面的代码非常适合我。
【问题讨论】:
-
您不需要更改其他表......这个SQL查询是完美的......然后here is the way to auto complete paid orders以避免再次发生这种情况。
标签: mysql wordpress woocommerce