XF 1.5 Restoring a deleted user - is it possible

At 13:36 yesterday i some how deleted a member of 7 years with about 700 posts, no idea how i did it without realising.
Today we closed the forums down and tried the process in this thread

You can try to assign back all the posts and threads that that particular user made with these queries:

For posts

Code:
UPDATE xf_post SET user_id = x WHERE username ='oldusername';
For threads

Code:
UPDATE xf_thread SET user_id = x WHERE username ='oldusername';
And replace x with that member new id and oldusername with their old username

Then you might need to run the Rebuild Caches option at your acp. Hope it helps.

That didn't seem to work so we tried a few other DB edits but we ended up restoring the forums to before we started messing about.

Has anyone else got any suggestions on how we can restore this user or is it loose 36 hours of forum posts and restore from the last backup
 
or is it loose 36 hours of forum posts and restore from the last backup

This is your only solution. Also you need to address the following two directories:

data
internal_data

These hold the attachments so please make sure these are being restored as well, otherwise you will lose all the attachments for this user.
 
This is your only solution. Also you need to address the following two directories:
It is not!

@bushcraft Tone
If you have a recent backup of both DB and filesystem, it is possible to restore pretty much everything without loosing other data.

But that requires some time and expert knowledge.
I know what I am talking about, I've done this a few times already and it is not fun - but definitly doable.

You might want to get in touch with @Xon who already partly automated this process.

Please don't mess with the DB yourself if you don't know exactly what you are doing; in many cases this causes more damage than necessary.
 
  • Like
Reactions: Xon
Back
Top Bottom