MyBB Community Forums

Full Version: myBB sql query to change forum ID
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
How can I change forum ID? Like this..

http://www.vbulletin.com/forum/showthrea...48b7447907

For example I want to change /forum-3.html to /forum-1.html



Run these;
UPDATE `announcements` SET `fid` = '1' WHERE `fid` =5;
UPDATE `delayedmoderation` SET `fid` = '1' WHERE `fid` =5;
UPDATE `forumpermissions` SET `fid` = '1' WHERE `fid` =5;
UPDATE `forums` SET `fid` = '1' WHERE `fid` =5;
UPDATE `forumsread` SET `fid` = '1' WHERE `fid` =5;
UPDATE `forumsubscriptions` SET `fid` = '1' WHERE `fid` =5;
UPDATE `moderatorlog` SET `fid` = '1' WHERE `fid` =5;
UPDATE `moderators` SET `fid` = '1' WHERE `fid` =5;
UPDATE `posts` SET `fid` = '1' WHERE `fid` =5;
UPDATE `reportedposts` SET `fid` = '1' WHERE `fid` =5;
UPDATE `threads` SET `fid` = '1' WHERE `fid` =5;

Replace 5 to the forum ID you want to Change.
Make sure you take a backup before running any of these queries as you will not be able to change it back
Probably be easier & safer to just move all the threads to the forum you want them to be in (and/or create a new empty forum with the ID you want and then move them). There are too many things that can go wrong otherwise, since forum IDs are references in so many places (caches too).

Even better solution would be to never attempt to change any ids at all.