Accidentally Deleted Thread

Vet

Member
I accidentally deleted a thread thinking I was deleting a post. Is there a way to recover the thread?
 
If you've got a backup, import it to a new database (you don't want to overwrite the existing one!) and use a graphical MySQL manager (I use SQLYog) or phpMyAdmin to find the thread in your xf_thread table. Export that row to an SQL file or copy the row insert information.

Then, use that thread ID to lookup the matching posts in the xf_post table (using something like "select * from xf_post where thread_id = x"). Export those posts in the same way.

You can then import just those row to your existing database and run a recount :).

Of course, be sure to backup your current database too - as I wouldn't want this to break anything!!!
 
  • Like
Reactions: Vet
Top Bottom