Advertisement:

Author Topic: Converting from YaBB 2.2  (Read 152851 times)

Offline baycrew

  • Semi-Newbie
  • *
  • Posts: 14
Re: Converting from YaBB 2.2
« Reply #100 on: July 11, 2008, 07:04:22 PM »
Being that I'm a very ansy kind of guy I decided to cut and paste the PM code section from the 2.2 converter to the 2.1 converter and it looks as though everything came over correctly EXCEPT for the time stamp of the PM.

I have "December 31st, 1969"

Is this what you see?


Offline SleePy

  • Let there be light!
  • Site Team Lead
  • SMF Master
  • *
  • Posts: 30,781
  • Gender: Male
  • Thats his happy face.
    • jdarwood007 on GitHub
    • @jdarwood on Twitter
    • SleePy Code - My personal site
Re: Converting from YaBB 2.2
« Reply #101 on: July 11, 2008, 07:38:26 PM »
Find:
Code: [Select]
                    'msgtime' => empty($userData[$i][6]) ? (int) $userData[$i][6] : '0',
Replace:
Code: [Select]
                    'msgtime' => !empty($userData[$i][6]) ? (int) $userData[$i][6] : '0',
As well you could use the attached. I did try to fix some of the bbc code. I haven't worked out yet how to deal with the timestamp bbc nor the /me. But I try to change others and fix them up :)

Jeremy D — Site Team / SMF Developer
Support the SMF Support team!
Profiles:
GitHub

Offline baycrew

  • Semi-Newbie
  • *
  • Posts: 14
Re: Converting from YaBB 2.2
« Reply #102 on: July 11, 2008, 08:18:08 PM »
Sleepy - take a look at this code when you have a moment. I still am getting the SET_ID_TOPIC error, but I think the syntax of your suggested fix isn't correct. It's as though you are adding an enclosure "{" where it doesn't belong (forgive me, I am not a programmer).

Here is what it looks like in your last attachment:

Quote
      {
         $result = convert_query("
            SELECT ID_TOPIC
            FROM {$to_prefix}log_topics
            GROUP BY ID_TOPIC
            HAVING COUNT(ID_MEMBER) > 1");

         while ($row = mysql_fetch_assoc($result))
            convert_query("
               DELETE {$to_prefix}log_topics
               SET ID_TOPIC = $row[ID_TOPIC]");
         mysql_free_result($result);

         pastTime(-3);
      }

and here is what it would look like with your suggested changes:

Quote
      {
         $result = convert_query("
            SELECT ID_TOPIC
            FROM {$to_prefix}log_topics
            GROUP BY ID_TOPIC
            HAVING COUNT(ID_MEMBER) > 1");

            while ($row = mysql_fetch_assoc($result))
            {
                convert_query("
                    DELETE {$to_prefix}log_topics
                    WHERE ID_TOPIC = $row[ID_TOPIC]");
         mysql_free_result($result);

         pastTime(-3);
      }

Thoughts?  :D

Offline SleePy

  • Let there be light!
  • Site Team Lead
  • SMF Master
  • *
  • Posts: 30,781
  • Gender: Male
  • Thats his happy face.
    • jdarwood007 on GitHub
    • @jdarwood on Twitter
    • SleePy Code - My personal site
Re: Converting from YaBB 2.2
« Reply #103 on: July 11, 2008, 09:29:39 PM »
yea.. Remove the extra {.
Sorry about that..

I have been working on converters all day making sure they shouldn't have any issues with 2.0 (when I release the 2.0 versions) and its just been line after line of code needing manual updates.
Jeremy D — Site Team / SMF Developer
Support the SMF Support team!
Profiles:
GitHub

Offline Gilrod

  • Semi-Newbie
  • *
  • Posts: 81
Re: Converting from YaBB 2.2
« Reply #104 on: July 12, 2008, 06:07:03 AM »
heh, got this ...

Quote
Converting...
Converting topics (part 2)... Unsuccessful!
This query:

    DELETE `tnmsv3`.smf_log_topics
    SET ID_TOPIC = 1;

Caused the error:

    You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'SET ID_TOPIC = 1' at line 2

Offline baycrew

  • Semi-Newbie
  • *
  • Posts: 14
Re: Converting from YaBB 2.2
« Reply #105 on: July 12, 2008, 07:43:15 AM »
heh, got this ...

Quote
Converting...
Converting topics (part 2)... Unsuccessful!
This query:

    DELETE `tnmsv3`.smf_log_topics
    SET ID_TOPIC = 1;

Caused the error:

    You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'SET ID_TOPIC = 1' at line 2

And I as well....

ThorstenE

  • Guest
Re: Converting from YaBB 2.2
« Reply #106 on: July 12, 2008, 01:00:47 PM »
try the attached version..

Offline Gilrod

  • Semi-Newbie
  • *
  • Posts: 81
Re: Converting from YaBB 2.2
« Reply #107 on: July 12, 2008, 02:56:35 PM »
What did you change? as it seems to be doing a lot of thinking.

ThorstenE

  • Guest
Re: Converting from YaBB 2.2
« Reply #108 on: July 12, 2008, 03:22:23 PM »
i changed
Code: [Select]
while ($row = mysql_fetch_assoc($result))
convert_query("
DELETE {$to_prefix}log_topics
SET ID_TOPIC = $row[ID_TOPIC]");
mysql_free_result($result);

to
Code: [Select]
while ($row = mysql_fetch_assoc($result))
convert_query("
UPDATE {$to_prefix}log_topics
SET ID_TOPIC = $row[ID_TOPIC]");
mysql_free_result($result);

i'm not 100% sure, but i think this must be an update of the log_topics-table..

also possible could be

Code: [Select]
while ($row = mysql_fetch_assoc($result))
convert_query("
DELETE FROM {$to_prefix}log_topics
WHERE ID_TOPIC = $row[ID_TOPIC]");
mysql_free_result($result);

i cannot test myself (i think it's time to install a Yabb for me)

Offline SleePy

  • Let there be light!
  • Site Team Lead
  • SMF Master
  • *
  • Posts: 30,781
  • Gender: Male
  • Thats his happy face.
    • jdarwood007 on GitHub
    • @jdarwood on Twitter
    • SleePy Code - My personal site
Re: Converting from YaBB 2.2
« Reply #109 on: July 12, 2008, 04:16:48 PM »
It was meant to be a delete :)

The first query before it was finding the duplicate ids. This query is using that information to remove them to prevent the duplicate id error when adding the primary index back :)
Jeremy D — Site Team / SMF Developer
Support the SMF Support team!
Profiles:
GitHub

Offline Gilrod

  • Semi-Newbie
  • *
  • Posts: 81
Re: Converting from YaBB 2.2
« Reply #110 on: July 12, 2008, 09:16:47 PM »
well it doesn't work...

After re-doing it all from scratch I just get a "done" in the status bar during topics (2)

:(

Offline SleePy

  • Let there be light!
  • Site Team Lead
  • SMF Master
  • *
  • Posts: 30,781
  • Gender: Male
  • Thats his happy face.
    • jdarwood007 on GitHub
    • @jdarwood on Twitter
    • SleePy Code - My personal site
Re: Converting from YaBB 2.2
« Reply #111 on: July 13, 2008, 12:35:23 AM »
Does it keep refreshing while its in progress of its work?

What is the querystring (The part after the ? in the url)?
This would let me know exactly what step it is currently on (or possibly a step after that) and such.
Jeremy D — Site Team / SMF Developer
Support the SMF Support team!
Profiles:
GitHub

Offline Gilrod

  • Semi-Newbie
  • *
  • Posts: 81
Re: Converting from YaBB 2.2
« Reply #112 on: July 13, 2008, 04:00:03 AM »
ah balls, I closed it down... will restart it now and report back in like 4hrs...

Stew

Offline Gilrod

  • Semi-Newbie
  • *
  • Posts: 81
Re: Converting from YaBB 2.2
« Reply #113 on: July 14, 2008, 04:58:24 AM »
Quote
http://tnmsv3.jawltd.com/convert.php?step=1&substep=26100&cstep=8&start=0

Arriving considerably later than planned, my net connection died at 9am on Sunday!!!!

Offline SleePy

  • Let there be light!
  • Site Team Lead
  • SMF Master
  • *
  • Posts: 30,781
  • Gender: Male
  • Thats his happy face.
    • jdarwood007 on GitHub
    • @jdarwood on Twitter
    • SleePy Code - My personal site
Re: Converting from YaBB 2.2
« Reply #114 on: July 14, 2008, 12:54:23 PM »
Ok, well you are stuck on step 8.
 
How many topics do you have on your board?
 
from the url you gave me it is showing 26,100 topics so far have been converted and fixed.
Jeremy D — Site Team / SMF Developer
Support the SMF Support team!
Profiles:
GitHub

Offline Gilrod

  • Semi-Newbie
  • *
  • Posts: 81
Re: Converting from YaBB 2.2
« Reply #115 on: July 14, 2008, 04:03:12 PM »
27635 - Topics....

Offline SleePy

  • Let there be light!
  • Site Team Lead
  • SMF Master
  • *
  • Posts: 30,781
  • Gender: Male
  • Thats his happy face.
    • jdarwood007 on GitHub
    • @jdarwood on Twitter
    • SleePy Code - My personal site
Re: Converting from YaBB 2.2
« Reply #116 on: July 14, 2008, 05:57:58 PM »
Is it still running?

It just hasn't completed yet then. Its only done 26k out of the almost 28k topics you have. It is getting there.
Jeremy D — Site Team / SMF Developer
Support the SMF Support team!
Profiles:
GitHub

Offline Gilrod

  • Semi-Newbie
  • *
  • Posts: 81
Re: Converting from YaBB 2.2
« Reply #117 on: July 14, 2008, 06:33:07 PM »
No dude, this has totally stopped...

And I've no idea why, the status bar = "DONE" and it's been sat at the 26000 for 1/2 a day.

Offline SleePy

  • Let there be light!
  • Site Team Lead
  • SMF Master
  • *
  • Posts: 30,781
  • Gender: Male
  • Thats his happy face.
    • jdarwood007 on GitHub
    • @jdarwood on Twitter
    • SleePy Code - My personal site
Re: Converting from YaBB 2.2
« Reply #118 on: July 14, 2008, 06:50:27 PM »
any continue button :|
If there is no continue button you can try hitting go in the url and see if you can get it to start again.
Jeremy D — Site Team / SMF Developer
Support the SMF Support team!
Profiles:
GitHub

Offline Gilrod

  • Semi-Newbie
  • *
  • Posts: 81
Re: Converting from YaBB 2.2
« Reply #119 on: July 15, 2008, 03:57:13 AM »
There was no continue button... at all... :(

I'll restart from scratch.