WordPress.org

Ready to get started?Download WordPress

Forums

Wondering about the Database (3 posts)

  1. Mark (podz)
    Support Maven
    Posted 10 years ago #

    If an entry / comment is deleted, am I right in thinking that it isn't actually deleted from the db, but simply marked in a way that the program ignores that data.
    Not that I want to do it (I'm just interested!), but is there a way - if what I said was correct - of reclaiming the space within the db that is taken by such data. Or would that completely screw things up given the inter-relating links ?
    A sort of db-defragging :)

  2. Jean-Pierre Michaud
    Member
    Posted 10 years ago #

    this technique of tagging posts to not delete them is not the one used here... look:
    $wpdb->query("DELETE FROM $tablecomments WHERE comment_ID = $comment");
    this is the db entry done when deleting a comment in the admin cp... so it's deleting the entry, completely... the only thing is that there is no optimisation of the tables in the process, but that may be added someday.

  3. Mark (podz)
    Support Maven
    Posted 10 years ago #

    Thanks .. that's my curiosity sated for a few hours :)

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.