Announcement

Collapse
No announcement yet.

Update user's info on imported threads?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Update user's info on imported threads?

    After we moved our board from UBB5 to vBulletin, we deleted all the registered users, except for the moderators, because we wanted people to re-register and agree to new terms of service. We didn't realize, though, that we wouldn't be able to update the post information after people had re-registered by running the update functions from vBulletin. As a result, not only are users post counts incorrect, but a search for posts by a user does not find any of the imported messages.

    Now that most of our members who are going to re-register have done so, is there a query we can run that would update the user name in the posts against the registered users?

  • #2
    when you delete a user in vBulletin the posts for that user are disassociated from their account. vBulletin doesn't have a feature to reassociate like you are wanting to do. i would post a hack request on www.vbulletin.org .

    Comment


    • #3
      I'm thinking we should be able to do this with an SQL query. The user name is still stored somewhere, as it shows on the posts. It's just not associated any longer with wherever the users data is stored. Does this not make sense?

      Comment


      • #4
        Originally posted by samtha25
        Does this not make sense?
        yeah, that makes sense. i don't see why that couldn't be done... but don't ask me how! hehe. like i said before, you should post a hack request on www.vbulletin.org . there are some talented guys and gals over there that can probably help you.

        Comment


        • #5
          I suffer from ataxiophobia (fear of disorder). I figure this falls under the realm of Jelsoft support. Maybe someone will come along with some help.

          Comment


          • #6
            Anyone?

            Comment


            • #7
              Originally posted by samtha25
              I suffer from ataxiophobia (fear of disorder). I figure this falls under the realm of Jelsoft support. Maybe someone will come along with some help.
              this would require hacking and running queries to associate new members with the old ids - you'll have to ask at vbulletin.org though

              in order to use and post in certain forums at vBulletin.org you need to

              1. register using the same username and email address you used at vBulletin.com's forums
              2. activate and confirm your registration email
              3. then enter your forum username at http://www.vbulletin.com/members/vbulletin.org.php to show that you're a licensed vB owner
              :: Always Back Up Forum Database + Attachments BEFORE upgrading !
              :: Nginx SPDY SSL - World Flags Demo [video results]
              :: vBulletin hacked forums: Clean Up Guide for VPS/Dedicated hosting users [ vbulletin.com blog summary ]

              Comment


              • #8
                This can't be handled with just a SQL query to update the database? I don't care about matching people who register in the future with their old username, only with matching up those that have registered to date. All the old members that were going to re-register have done so by now.

                Comment


                • #9
                  Originally posted by samtha25
                  This can't be handled with just a SQL query to update the database? I don't care about matching people who register in the future with their old username, only with matching up those that have registered to date. All the old members that were going to re-register have done so by now.
                  i'm no coding guru, but i do believe something like this would require logic that only php code could provide. it wouldn't be just a simple mysql query.

                  Comment


                  • #10
                    I don't think PHP's intervention would be necessary to manipulate the database. I just took a look at the Jelsoft documentation on the database. There is a table Post that contains, among other things: postid, threadid, username, and userid. Then, there is a table User that contains, among other things: userid, usergroupid, username.

                    I assume the username is still stored with the post data since it displays with the post, but that the userid is not. So what I need, I think, is an SQL query that will check a username in table User against each post and where it finds a match and the userid field empty, writes the userid to userid field in table Post. Or, conversely, the query might find each post with an empty userid field, check for a match between the username in table Post and the usernames in table User, then write the userid from the User table to the Post table if a match is found.

                    Doesn't that sound doable?

                    Comment


                    • #11
                      Originally posted by samtha25
                      I assume the username is still stored with the post data since it displays with the post, but that the userid is not. So what I need, I think, is an SQL query that will check a username in table User against each post and where it finds a match and the userid field empty, writes the userid to userid field in table Post. Or, conversely, the query might find each post with an empty userid field, check for a match between the username in table Post and the usernames in table User, then write the userid from the User table to the Post table if a match is found.

                      Doesn't that sound doable?
                      that's exactly what i was thinking would need to be done. so either we both have the right idea or we both don't know what we're talking about.

                      what i meant in my last post is that i don't think you can compare info from multiple tables and update userids in the post table accordingly using a mySQL query. this can be done with php though.

                      regardless of the process, you won't get help on these forums for this particular problem. if you post a request on www.vbulletin.org some one might be able to help you.

                      Comment


                      • #12
                        OK I surrender. I've sent a note to our tech support to see if they can figure it out - for the usual fee. Thanks anyway.
                        Last edited by samtha25; Wed 15th May '02, 10:29am.

                        Comment

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