• micasuh

    (@micasuh)


    I went into phpMyAdmin and what I found confuses me. With every new post/page I create, there are two rows created:

    1) publish/save/draft status that I purposely set
    2) inherit status that it auto creates

    On 2), the permalink set is always “123-revision-1”, where “123” is the post ID and “revision-1” is an append for this duplicate entry.

    This happens with or without plugins activated. My .htaccess file only contains default WordPress settings and wp-config.php is also default.

    Does anyone have any clue what’s going on here?

    Visual example here

Viewing 2 replies - 1 through 2 (of 2 total)
  • This is just part of the Revisions system. What you’re seeing is the first ‘revision’.

    Revisions are stored as children of their associated post (the same thing we do for attachments). They are given a post_status of ‘inherit’, a post_type of ‘revision’, and a post_name of {parent ID}- revision(-#) for regular revisions and {parent ID}-autosave for autosaves.

    Thread Starter micasuh

    (@micasuh)

    This is just part of the Revisions system. What you’re seeing is the first ‘revision’.

    Is it supposed to save the post and first revision at the same time?

    You can see in the image I linked to that the post has an appended -2 to the post_name column for the permalink and my assumption was because it had to create the additional Insert post.

    • This reply was modified 7 years ago by micasuh.
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘New post creation causes double row entries in mySQL’ is closed to new replies.