PDA

View Full Version : Changing userid in posts


GMan55
03-28-2013, 04:59 AM
I had previously deleted a user from my forum. I wish to bring the user back. The user seems to be back, but the posts are not associated with the user. In phpmyadmin, there is a posts table. As I change the userid in that table for that user from 0 to the user's original user id, the user is starting to get his posts back. Is there a way I can speed this up for all the posts using sql query?

Thanks.

Brandon Sheley
03-28-2013, 03:05 PM
http://www.vbulletin.com/forum/forum/vbulletin-legacy-versions-products/legacy-vbulletin-versions/vbulletin-3-7-questions-problems-and-troubleshooting/289768-restoring-a-deleted-member?

https://www.google.com/search?q=restore+deleted+users%2C+vbulletin

I'd look over the thread and search, there was a mod at one time if I remember right, but not sure if it's for vb4 or not.

x iJailBreak x
04-01-2013, 06:32 PM
I had previously deleted a user from my forum. I wish to bring the user back. The user seems to be back, but the posts are not associated with the user. In phpmyadmin, there is a posts table. As I change the userid in that table for that user from 0 to the user's original user id, the user is starting to get his posts back. Is there a way I can speed this up for all the posts using sql query?

Thanks.

Ideally you need to run a query on all tables that have a "userid" column and change the old userid to the new one. I did this successfully on my own forum. Be wary, it's not recommended.