Reputation: 553
I try to anonymize WooCommerce for debug access by third party plugin developers with a bash command line script on my linux server. I successfully could remove users and orders but now I discover that all the sales statistics are still available in WooCommerce' Analytics including names and figures. Where do I find this in database so I can include it my database query to address it?
By request I include here a screenshot of WC analytics' first page with sales and order reports, financial data not to be revealed to a plugin author.
Upvotes: 0
Views: 2392
Reputation: 11
I got this same problem and resolve it via SQL.
Try use this SQL to remove orders stored in WooCommerce analytics:
DELETE FROM [TABLE_PREFIX]_wc_order_stats;
DELETE FROM [TABLE_PREFIX]_wc_order_coupon_lookup;
DELETE FROM [TABLE_PREFIX]_wc_order_product_lookup;
Upvotes: 1
Reputation: 2578
Truncate wp_wc_order_stats table and go to Tools and press "Clear analytics cache". That worked for me.
Upvotes: 0
Reputation: 683
Try to run WooCommerce > Status > Tools > Clear Analytics Cache
tool. Analytics dashboard is using a lot of caching, otherwise it would be too slow. Before clearing the cache, make sure you empty the orders from the trash too.
And while you are on the WooCommerce > Status > Tools
page, delete all transients too.
Upvotes: 5