Results 1 to 2 of 2

Thread: Shrink Your Wordpress Databases by Deleting Revisions

Hybrid View

  1. Shrink Your Wordpress Databases by Deleting Revisions

    When you update a blog post, Wordpress stores the old version of your post as a revision document. If you make very many updates, these revisions can have a significant impact on your database size. On some of my Wordpress sites, half the blog posts stored in the DB were revisions.

    If you're sure that you don't need these older versions of your blog posts, you can delete them permanently with this MySQL command:
    Code:
    DELETE FROM wp_posts WHERE post_type = "revision";
    You might want to make a database backup first.
    Submit Your Webmaster Related Sites to the NB Directory
    I swear, by my life and my love of it, that I will never live for the sake of another man, nor ask another man to live for mine.

  2. #2
    After deleting the post revisions, add the following to the wp-config.php script. It disables post revisions. I added this to all of my blogs.
    Code:
    define('WP_POST_REVISIONS', false);
    For most WordPress sites, tracking post revisions is a useless feature.
    "Democracy is two wolves and a lamb voting on what to have for lunch. Liberty is a well-armed lamb contesting the vote." -- Benjamin Franklin


Similar Threads

  1. Deleting Facebook Posts
    By Will.Spencer in forum Social Networks
    Replies: 6
    Last Post: 13 August, 2010, 11:28 AM
  2. Deleting accounts with 0 posts
    By Sbfc_ in forum Community Building
    Replies: 10
    Last Post: 16 May, 2010, 10:45 AM
  3. Smowtion deleting all my proxies
    By Habaku in forum Web Proxies
    Replies: 9
    Last Post: 29 March, 2010, 16:51 PM
  4. Merging Wordpress Databases
    By garfish in forum Wordpress
    Replies: 6
    Last Post: 5 December, 2009, 15:41 PM
  5. Replies: 0
    Last Post: 13 July, 2009, 19:12 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •