Re: Hi I'm new and need information
Reply #10 –
Okay, here we are.
Long lasting problem: merging two forums.
Merge two Elk installs is not entirely *so* easy.
OpenImporter doesn't really help on this, because the script is developed considering the need to import from an existing forum platform to a new install of another platform. So one of the first things that OI does is to wipe out any data from the destination database.
Assuming you would be good enough to have a merge of the posts (i.e. no personal messages) the cleanest way to "merge" two forums would be to take each message from the "source" database and create an entirely new post in Elk (to ensure consistency of the database), then update the necessary fields (like time of creation).
Assuming this can be done somehow easily, this approach would have quite a drawback: in ElkArte both messages and topics are sorted by the "id" of the topic (not by the data of creation), the design choice was taken a looooooooooooong way ago because the key is supposed to always be representative of the position of the topic in the time-based order and this saves the creation of an index ensuring the best performances.
I proposed a while ago to drop this requirement (i.e. add an index to the time columns of topics and messages tables and sort by that) because nowadays, space is cheap and the performance loss is risible (in fact it would be the additional time necessary when a topic/post is created in order to update an additional index). But honestly I didn't invest much time, because the only advantage would be exactly this: be able to merge two forums without many side-effects. And this is not really a frequent case. Annoying for the one facing the situation, indeed, but still a quite limited problem.
I think the merging script could be sorted out somehow, in theory it could even be possible to merge two existing forums into a third preserving the sorting, it's a bit more complex, but it's not impossible.