• Roy

    (@gangleri)


    A minor thing, but it’s bugging me still, so…

    I created a website for a band. When still in test, the website was a subsite of my own multi-install. Later I exported the content, installed WP on the band’s server and imported the little content that I made when testing. The strange thing is that the post IDs were included in the export, so the very first post we made had ID 119, the next 121 and then rocket-up to 185, 277, 308 and 311.

    The first thing that annoys me is the ID of the first post. Can’t I just make WP start with 1 and all the unused IDs that were skipped?
    Second the rocketing up numbering. Yes I did disable revisions, no there is nothing in the trash and yes there are pages, but not THAT many and the page IDs go up as fast as the posts. Quite some images which explain some.

    But the most ‘important’ thing is the starting above ID 100.

Viewing 4 replies - 1 through 4 (of 4 total)
  • esmi

    (@esmi)

    Can’t I just make WP start with 1 and all the unused IDs that were skipped?

    Sorry but no. The ids are set by the database. Once in place, they are incremented automatically.

    Thread Starter Roy

    (@gangleri)

    Ok, thanks for clearing that up.
    (I guessed as much ?? ).

    EnglishMike

    (@stringfold)

    Pages and posts are stored in the same database table (pages are essentially just a special type of post. Autosaves are also added to the same database table, which will keep the numbers bumping up too.

    In the end, the only thing to do is stop worrying about it. I think a lot of people are bugged by this at first, but after a while you’ll probably wonder why you ever did!

    The best thing to help you get there is not use post ids anywhere. Use permalinks that use the posts creation date and title instead. Out of sight, out of mind ??

    gulliver

    (@gulliver)

    That behaviour puzzles and bugs me too.

    And so does ‘Oh that’s just WP – learn to live with it, use title-based permalinks, etc.’ And too often, I’ve seen ‘it’s the database, not WP’.

    1. There can be good reasons for using post IDs as links – and whereso, sequential gapless numerbering is logical.

    2. And rather than ‘the database’, the issue is one of how WP interacts with it – for example, Movable Type generates no-gap numbers.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Post ID’ is closed to new replies.