I want to combine two historically separate forums as one.
I think I know how to slog through this with a perl DBI script and command line sql.
Select several columns from phorum_messages, from both databases, as needed. First one then the other.
Store each message in a file whose name is the original datestamp post date. First line author_id. Second line data. Third line etc whatever else might be needed. I'd have to look more carefully at phorum_messages.
Prepare a new database as a copy of the bigger of the two originals.
Now delete * from phorum_messages (now you have phorum_users etc, as they are needed).
Make a list file names (which are same as datestamp) as a text file list sorted by date (sorted by file name, which is datestamp).
Read each such file in a loop. Bust it up into an array of values.
Insert one by one, into the new database name.
I'm probably missing something but it seems quite doable.
Is there a utility or plugin to do this without the all-day slog?
Edited 5 time(s). Last edit at 05/04/2018 05:39PM by salmobytes.