The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Merging multiple forums? Anybody have experience with this?
Does the IMPEX importer work to merge multiple vBulletin sites into one database?
I'm talking about merging everything. Obviously lots of individual ID's for different things would need to be changed, i.e. posts, threads, users, everything, in order not to collide with eachother. Has anybody else done this before? |
#2
|
||||
|
||||
I don't think that ImpEx will work without a little thinking.
Here's why: When you run impex it takes posts threads userID's etc.. from the database you've provided in the impex config. Lets call this database vb_A. So lets say you have vb_A, vb_B, and vbC. vb_A = Old VB forum vb_B = 2nd old VB forum vb_C = New VB installation DB ImpEx will take everything from vb_A and import it into vb_C. if you change the config to use vb_B and run ImpEx it will first clear the DB tables and then run so you will lose all info previously imported from vb_A... SO What you'd have to do is this: set impex config to import from vb_A to vb_C then copy vb_C to a new DB such as vb_importedA now clear the DB vb_C just incase change impex config to import vb_B to vb_C run impex and let it import again copy vb_C to vb_importedB You now have 2 databases, vb_importedA and vb_importedB which will work with your new VB version. The problem is that userID's, groups, threads, etc... will have their own ID numbers since ImpEx starts at 0 and increments. So lets keep vb_importedA and vb_importedB as a backup incase anything goes wrong and work with vb_C. clear it and import whichever DB is more important to you, as far as groups, admins etc go. This is the part I'm not 100% sure about and may need help, but you'll need to work with the other DB and change userID's. So lets say we reimport vb_A to vb_C - now the old forum with vb_A will work with the new vbulletin forum so we need to fix the other old forum to work. So make a new DB and call it vb_editB Copy vb_importedB to vb_editB Overview: We now have vb_A = old forum1 vb_B = old forum2 vb_C = DB that the new forum will use vb_importedA = impex imported version of forum1 vb_importedB = impex imported version of forum2 vb_editB = the test imported version of forum2 which we can safely mess with First thing you will need to do is seperate UserID's, threadID's and postID's from the imported A forum1 values. So lets increment everything by 1,000 (larger if you have a huge forum) to set a gap between the forum1 and 2 ID's so if UserID=1 for forum1, UserID for forum2 will start at 1001 //Select database vb_editB and run Code:
UPDATE user SET user.userid = (user.userid + 1000) Code:
UPDATE thread SET thread.threadid = (thread.threadid + 100000) Code:
UPDATE thread SET thread.postuserid = (thread.postuserid +1000) Code:
UPDATE post SET post.threadid = (post.threadid + 100000) UPDATE post SET post.postid = (post.postid + 500000) UPDATE post SET post.userid = (post.userid + 1000) Code:
UPDATE forum SET forum.lastthreadid = (forum.lastthreadid + 100000) Now you should be able to export tables: forum, user, post, and thread and then reimport them into vb_C (make sure not to add the drop table if exist!) and it "should" work. I just came up with this so please take caution and MAKE BACKUPS of everything please. I don't want to be responsible for any mistakes. Also, I incremented userID's by 1000, ThreadID's by 100,000 and PostID's by 500,000 You want to create a sufficient "gap" between forum1 and 2 so increase these numbers if you think they will overlap. As for hacks and mods that you want to carry over, pay attention to the ImportuserID that impex used to make comparisons. Like importing the arcade hack (example): This will compare the importeduserID's (which match the current arcade userID's and if they match it updates the arcade userID to match the current userID Code:
UPDATE arcade_users, user SET arcade_users.userid = user.userid WHERE arcade_users.userid = user.importuserid; Code:
UPDATE arcade_users, user SET arcade_users.userid = (user.userid +1000) WHERE arcade_users.userid = user.importuserid; I am not an expert at this, I just like to tinker |
#3
|
||||
|
||||
Wow, thanks for the really detailed reply. I will definitely do all of this in a test area to make sure it works. As for the arcade, it's probably easier just to delete all scores and start over.
As for the userid problems, I can use the user merge function that is built standard into vB. :-) |
#4
|
|||
|
|||
Sorry to disappoint you, but ImpEx is designed to do also this task, will not need anything as described in post #2.
Yes you can merge 2 forums with ImpEx (A->C + B->C or just B->A) without any manual tweaking at all. Just make sure to finalize the first import (in a A->C + B->C situation) before starting the second import. See the ImpEx online documentation and/or read in the Import System forum at vb.com. PS Doing some testruns on a testboard first is always a good idea. PSS Moving this to General vB discussions |
#5
|
||||
|
||||
Not disappointing at all, I love the ImpEx script!
So you can import forumA and B into C by resetting the importuserID columns to 0 and then starting the next import? I was sure that it drops data from existing tables during the import |
#6
|
|||
|
|||
well, I am trying to do this and did a good job with the first import but I am about clueless as to what to change in the config file for the second import.
It all seems to point to data on my server but how to I make it point to that particular forum to extract the file is still a mystery for me. |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|