Converting from Phorum 5.2 (to SMF 2.1.3) - nothing happens

Started by mroek, December 03, 2022, 09:24:10 PM

Previous topic - Next topic

mroek

I have successfully installed SMF 2.1.3, and I have downloaded the converter for Phorum. However, when I run the converter and enter the required info, it does nothing. it just its there like this:

You cannot view this attachment.

Both Phorum and SMF are at the same host and in the same database.

Any pointers as to why nothing happens (no errors, absolutely nothing), and how to best diagnose the issue?

mroek

So it just dawned on me that the converter is specifically for converting to SMF 2.0.19. I guess that's why it doesn't work, and that I must install the older SMF first, then convert, and after that update to SMF 2.1.3.

mroek

Using SMF 2.0.19 works a lot better, and it gets all the way to PMs before choking with this error:

Converting personal messages (step 1)... Unsuccessful!
This query:

    SELECT
    p.private_message_id AS id_pm, p.from_user_id AS id_member_from,
    p.datestamp AS msgtime,
    SUBSTRING(IFNULL(u.username, p.from_username), 1, 255) AS from_name,
    SUBSTRING(p.subject, 1, 255) AS subject,
    SUBSTRING(p.message, 1, 255) AS body, p.from_del_flag AS deleted_by_sender
    FROM `dynator`.phorum_private_messages AS p
    LEFT JOIN `dynator`.phorum_users AS u ON (u.user_id = p.from_user_id)
    LIMIT 0, 500;

Caused the error:

    1146

I'm not very good with SQL, so I'm not sure what the problem is. Any pointers would be greatly appreciated.

And also, is it safe to run the converter multiple times (while trying to resolve problems)? It appears to "convert" additional posts on each subsequent run, but the number of messages in the DB seems correct when comparing the Phorum source table and the SMF destination table.

Starting over by dumping all tables and then re-install and re-convert is of course a possibility, but not having to would be nice.

Doug Heffernan

Is there any detailed error message or just that number? MySQL 1146 error means that table doesn't exist.

mroek

Sorry for the monologue and repeated posting. This error seems to appear because my Phorum uses different table and column names to what the script expects (for PMs). Fixing it will be a bit of work, so I think I'll just skip the PMs altogether.

mroek

Quote from: Doug Heffernan on December 04, 2022, 07:22:41 AMIs there any detailed error message or just that number? MySQL 1146 error means that table doesn't exist.
Thanks for replying!
As I just wrote, the structure of PMs in my Phorum (version 5.2.13) appears to be wildly different to what the script expects. The most complicated part is that it doesn't keep recipient info in a column, instead it has a "meta" column with encoded information like so:

a:1:{s:10:"recipients";a:1:{i:8;a:3:{s:7:"user_id";i:8;s:9:"read_flag";s:1:"1";s:12:"display_name";s:8:"actual recipient name here";}}}

Decoding this is of course not that difficult, but also not important enough for me to care. I'll just find a way to skip the PM step altogether, I think.

Do you happen to know if running the script multiple times is safe, or if I should restart all from scratch after figuring out these problems? I wonder why it seems to always find new posts to convert, even if all posts are seemingly already converted.

holleformula

The conversion is still running and outputting dashes. Is it really still working, or might it be in some kind of weird loop, or am I just being impatient?

mroek

Quote from: holleformula on December 08, 2022, 09:55:48 AMThe conversion is still running and outputting dashes. Is it really still working, or might it be in some kind of weird loop, or am I just being impatient?
Probably best if you created your own thread for your issue, as I don't think it is related to my thread, right?

As a side note, I edited the SQL script to just skip the PMs of my old forum, and it all went smooth for me. After that, I updated to the latest SMF version, and finished everything up. Had to manually do some operations in the database to fix minor issues, but all is good now.

Doug Heffernan

Quote from: mroek on December 13, 2022, 07:35:50 AMHad to manually do some operations in the database to fix minor issues, but all is good now.

Glad to hear that you converted your forum successfully to Smf. I am marking this as solved.

Advertisement: