Stupid question on post numbering in VB

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Dragon
    Member
    • May 2000
    • 88

    Stupid question on post numbering in VB

    Hi,

    According to the counter on the front page, my vBulletin says we are approaching 100,000 total posts. But if I go into "Edit post" (because I couldn't figure out how else to display the nth post), I find that recent posts are numbered 116000 or so.

    1. Why this disparity?
    2. How could I reliably know which is the 100,000th post?

    Thanks in advance...
  • JimF
    Senior Member
    • May 2000
    • 1988

    #2
    The disparity comes from deleted threads. For example if you have thread id's 001, 002, & 003, and you delete thread 002, that number is gone forever. One counter may show three total posts, since thread 003 is the highest number, though another counter might show 2 posts since thread 002 doesn't exist any more.

    With that reasoning, the chances are good that the lower number is the amount of actual posts in the database - the larger number would be representative of the highest number id.

    -jim

    Comment

    • Dragon
      Member
      • May 2000
      • 88

      #3
      That makes sense, although I haven't deleted any significant number of posts since importing everything from UBB. I wonder if the higher number includes posts that have been deleted or abandoned in the editing process by users, though. In any case, thanks!

      Comment

      • JimF
        Senior Member
        • May 2000
        • 1988

        #4
        UBB posts get imported sequentially as well, I think. It's been a while since I've done a UBB import, but I'm pretty sure that threads that were deleted in UBB remain deleted in vB, i.e. if there is no thread number 002 in UBB, there won't be a thread 002 in vB either. That could be what you're seeing.

        -jim

        Comment

        • Freddie Bingham
          Former vBulletin Developer
          • May 2000
          • 14057
          • 1.1.x

          #5
          Yes that would include any posts deleted by your users and all posts removed when a thread is deleted.

          Comment

          • dwh
            Senior Member
            • Sep 2000
            • 1224
            • 3.0.0 Release Candidate 4

            #6
            What probably happened is you imported posts, deleted them, reimported them....the numbering of posts doesn't start from 0 just because you deleted posts, the counter keeps going up...

            Comment

            • Dragon
              Member
              • May 2000
              • 88

              #7
              OK, so...

              ...how do I actually query to find the 100,000th post?

              Comment

              • Fquist
                Senior Member
                • Apr 2000
                • 227

                #8
                Uh..I don't have the money for a vb license(*sob*) but my guess would be something like this:

                select * from replies where postid = '100000'
                Site: -http://www.jazz2online.com-
                Forums -http://www.jazz2online.com/jcf/-

                Comment

                • Mike Sullivan
                  Former vBulletin Developer
                  • Apr 2000
                  • 13327
                  • 3.6.x

                  #9
                  That would get the post with number 100,000, but not necessarily the 100,000th post currently in the database.

                  To get post with number 100,000:
                  SELECT * FROM post WHERE postid=100000;

                  To get the 100,000th post currently in the DB:
                  SELECT * FROM post LIMIT 100000,1;

                  Comment

                  widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                  Working...