Skip to content

Instantly share code, notes, and snippets.

@TimBHowe
Last active January 31, 2017 12:47

Revisions

  1. TimBHowe revised this gist Apr 29, 2015. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions remove_orders
    Original file line number Diff line number Diff line change
    @@ -1,4 +1,4 @@
    DELETE FROM wp_postmeta
    WHERE post_id IN(SELECT ID FROM wp_posts WHERE post_type = 'shop_orders');
    WHERE post_id IN(SELECT ID FROM wp_posts WHERE post_type = 'shop_order');

    DELETE FROM wp_posts WHERE post_type = 'shop_orders';
    DELETE FROM wp_posts WHERE post_type = 'shop_order';
  2. TimBHowe renamed this gist Mar 20, 2015. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  3. TimBHowe created this gist Mar 20, 2015.
    4 changes: 4 additions & 0 deletions gistfile1.sql
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,4 @@
    DELETE FROM wp_postmeta
    WHERE post_id IN(SELECT ID FROM wp_posts WHERE post_type = 'shop_orders');

    DELETE FROM wp_posts WHERE post_type = 'shop_orders';