Advertisement:

Author Topic: [SMF Converter] Yabb 2.2  (Read 120161 times)

Offline SleePy

  • Site Team Lead
  • SMF Master
  • *
  • Posts: 29,930
  • Gender: Male
  • Thats his happy face.
    • jdarwood007 on GitHub
    • @jdarwood on Twitter
    • SleePy Code - My personal site
[SMF Converter] Yabb 2.2
« on: July 14, 2008, 10:47:48 PM »
Software: Yabb
Version: 2.2.x
Supported SMF Database Types: MySQL *

This is the official support topic for Yabb converter.  You may use this topic or the Yabb/Yabb SE board to ask for support with this converter.

Note This converter is using a new method of conversion. If you experience any issues at all please let us know.
At this time there may be a bug with membergroups not creating post count based groups on their actual post based group numbers.

Changelog
! Rewrote the Yabb 2.2 converter to use a convert table during conversion instead of altering tables. (yabb22_to_smf.php)

convert.php
Use this convert.php with the .php file attached in this topic.
« Last Edit: July 18, 2009, 03:04:45 PM by TE »
Jeremy D — Site Team / SMF Developer
Support the SMF Support team!
Profiles:
GitHub

Offline edsager

  • Semi-Newbie
  • *
  • Posts: 11
Re: [Beta] [SMF Converter] Yabb 2.2
« Reply #1 on: October 05, 2008, 03:49:24 PM »
I am a bit frustrated with trying to find the necessary "yabb22_to_smf.sql" file. 

Where can I find this file?

Thank you,
edsager

ThorstenE

  • Guest
Re: [Beta] [SMF Converter] Yabb 2.2
« Reply #2 on: October 06, 2008, 01:42:14 AM »
the yabb converters use php-files (not .sql), the needed yabb22_to_smf.php is attached in SleePy's Message (above yours)

Offline edsager

  • Semi-Newbie
  • *
  • Posts: 11
Re: [Beta] [SMF Converter] Yabb 2.2
« Reply #3 on: October 12, 2008, 04:38:40 AM »
TE,

Thank you for the response.

What did SleePy mean with the statement, "Use this convert.php with the .sql file attached in this topic"?  This statement got me looking for a .sql file in the referenced topic.

Thanks,
edsager

ThorstenE

  • Guest
Re: [Beta] [SMF Converter] Yabb 2.2
« Reply #4 on: October 12, 2008, 05:54:57 AM »
Quote
Changelog
! Rewrote the Yabb 2.2 converter to use a convert table during conversion instead of altering tables. (yabb22_to_smf.sql)
Don't care about, it's only a note for us.. the old yabb converter (before it was rewritten) was an .sql file...

You only need the convert.php and the yabb22_to_smf.php from this topic.

Offline edsager

  • Semi-Newbie
  • *
  • Posts: 11
Re: [Beta] [SMF Converter] Yabb 2.2
« Reply #5 on: October 12, 2008, 10:50:11 PM »
Thank you!

edsager

Offline SleePy

  • Site Team Lead
  • SMF Master
  • *
  • Posts: 29,930
  • Gender: Male
  • Thats his happy face.
    • jdarwood007 on GitHub
    • @jdarwood on Twitter
    • SleePy Code - My personal site
Re: [Beta] [SMF Converter] Yabb 2.2
« Reply #6 on: October 13, 2008, 03:02:51 PM »
My bad, those instances should of been .php. That is what I get for copy and pasting ;)
I fixed them.
Jeremy D — Site Team / SMF Developer
Support the SMF Support team!
Profiles:
GitHub

ThorstenE

  • Guest
Re: [SMF Converter] Yabb 2.2
« Reply #7 on: February 27, 2009, 01:36:41 AM »
the yaBB converter needs a configuration file from your old YaBB:
Paths.pl
the Paths.pl contains the variables for your data dirs..

Quote
   $boardsdir = "./Boards";
   $sourcedir = "./Sources";
   $memberdir = "./Members";
   $vardir    = "./Variables";

I'll check my YaBB installation later this day, maybe I can post an example paths.pl

Offline pikarl

  • Semi-Newbie
  • *
  • Posts: 10
Re: [SMF Converter] Yabb 2.2
« Reply #8 on: February 27, 2009, 04:18:44 AM »
Hi TE,

thank you for this hint. I just try to convert my YaBB 2.2.1 to SMF, still with many errors. But I do not understand what exactly you mean: Should I copy those vars from Paths.pl into the yabb22_to_smf.php?

Another question: Is it suitable to use the current SMF version 1.1.8 as target for the conversion or should I use an older one?

Offline pikarl

  • Semi-Newbie
  • *
  • Posts: 10
Re: [SMF Converter] Yabb 2.2
« Reply #9 on: February 27, 2009, 07:22:56 AM »
I get the following error message in converting:

Code: [Select]
Converting personal messages (part 1)... Unsuccessful!
This query:INSERT IGNORE INTO `raumcon`.smf114_pm_recipients
(ID_PM, ID_MEMBER, labels, is_read)
SELECT pm.ID_PM, mem.ID_MEMBER, -1 AS labels, 1 AS is_read
FROM `raumcon`.smf114_personal_messages AS pm
INNER JOIN `raumcon`.smf114_convert AS c ON (c.real_id = pm.ID_PM)
INNER JOIN `raumcon`.smf114_members AS mem ON (mem.memberName = c.temp)
WHERE c.type = 'personal_messages'
AND pm.deletedBySender = 1;Caused the error:
Illegal mix of collations (utf8_general_ci,IMPLICIT) and (latin1_swedish_ci,IMPLICIT) for operation '='

I am trying to convert YaBB 2.2.1 to SMF 1.1.0 in this case. I got the same message when converting to SMF 1.1.4 or 1.1.8.

Offline pikarl

  • Semi-Newbie
  • *
  • Posts: 10
Re: [SMF Converter] Yabb 2.2
« Reply #10 on: February 27, 2009, 09:07:07 AM »
Hi,

I solved above problem now. My MySQL (4.1.13) is creating new tables in this strange swedish char set by default. I now created this convert table by myself in utf-8 and uncommented the following lines in yabb22_to_smf.php:

Code: [Select]
// convert_query("
// DROP TABLE IF EXISTS {$to_prefix}convert");

// convert_query("
// CREATE TABLE {$to_prefix}convert (
// real_id TINYTEXT NOT NULL ,
// temp TINYTEXT NOT NULL ,
// type TINYTEXT NOT NULL
// ) ENGINE=MYISAM");

Then it worked. But now I have a different problem:

I use the attachment function of YaBB. Now the converter tries not only to copy all the YaBB attachment images (11 MB) but additionally 1 GB+ of all images included in posts on external servers. That should not happen.

Any ideas?

ThorstenE

  • Guest
Re: [SMF Converter] Yabb 2.2
« Reply #11 on: February 27, 2009, 10:58:46 AM »
I don't know much about YaBB but the converter should not convert "external" Links as attachments. Is there a reference file for each "external" attachment in the YaBB attachments directory?

Offline pikarl

  • Semi-Newbie
  • *
  • Posts: 10
Ynt: [SMF Converter] Yabb 2.2
« Reply #12 on: February 27, 2009, 12:15:11 PM »
No, I just get lots of images with encrypted filenames. My /attachments looks like this:

Quote
9906_screenshot_jpgfb82eba9821f5664842e5b513e188056
9907_vdb152_benintende_klein_JPG8f12f350a78c13807763c2ef64fa459b
9908_W00043245_jpg230a67d4c529871013e79bcce09e648b
9909_W00043236_jpgaa39d205ebc0776680fada5c04db2cbb
990_vlcsnap-397588_png8e556ba923dbab88d54d7f8f7d80eead
9910_enceladus-flyby_Kopie_jpgec73482a7feba11ca92a076cebba3d06
9911_nz070812p_55_fireball_jpg581e1a3d0a292f05bfd19a6711a0413e
9912_saturnbedeckung_jpgb0cb78e292e6c64efbcd7b1423a2de23
9913_Christopher-Go1_strip_gif49fe6247d01ce1b1d068ed5df22178a6
9914_GRA-06129-Meteorit_jpgb537e6caf29fb208f899a0767e3eacec
9915_Sofi_2_e_best_geschnitten_jpg0766624a26d7005c2f3e70bf6b9dcb35
9916_IMG_9475-sommerdreieck_klein_JPG6ce206344fda9045297856929efbe57e
9917_IMG_3580a-02k_jpg237bca76a1e43f341a6c6c97cef5c999
9918_bg_raumfahrt_jpg0b9866893411521023d13d6e4cb813ac
9919_1000__jpg6672cd9c2c0b9ef7cb87613ffd567668
991_vlcsnap-399474_png61095e5cba7cab015959bf18f0f735d2
9920_ModMap_jpg9f6a19484f349194179080e5519da9fe
9921_ModMap2_jpg4b0c006b8d6aa2fa8eca24a03c597ee0
9922_ModMap2_001_jpg49335371b901066a0de2aa7692832f8c
9923_ModMap2_002_jpgf9c9fc3ef954213613e77cb263d65cc0
9924_ModMap3_jpg370311aeed17a490bdeaf9373680d421
9925_ModMap4_jpg94c5a4bf67bf61c8fb27704fd06c80fe
9926_besucher_png893c2fab67ca4190b1c43c8b95af7827
9927_titel_pngc0f7ea80d951a89c3848b5f5c0dffb4d
9928_ModMap5_jpg6326c442b37ff05b745e5af829c4e886
9929_paygar_jpgb1b7db360426e3959b6113b7c25e7efd
992_IMG_2447_jpgd520d5b90faed376f48fccd7cfc2f338
9930_tex_jpgf45cda7fa4d8c22e3d8f0fad80bb445d
9931_communitylink_png7a641be3587574e7eb090a60beb16353
9932_bild_JPGc087340014c3f3ad74d61a1006712669
9933_unterstreichung_png933b152cdb90e675dee46e4cd00768d2
9934_49_Mitglieder_115_Gste_JPGf2b3d940f1f6eb689a0a111ce33c5d01
9935_Mitglieder_Sep07_jpgd4774af6c19acad39ebe2fb2a9faf2c1
9936_Prsentation1_gif1ed2c7742a023a5b48f540b896baf942
9937_stat_png2fe382709accb963b1d23b28e8e3e541
9938_suchfeld_pngb43c7d9d36a3c4571a265b7bdc5ade60
9939_Ansicht_jpg353b607b27b3a1015a04bf81c0bbcf3d
993_IMG_2446_jpg81dd40230aa874b1592b4ee169d3233b
9940_screenshot_PNGe03c8ae8ed529a5552c9b19ba2f8e5c6
9941_screeny_pngd01b3183aa90f3e5c6e352c1a1ab1365
9942_sts122_png3a1f374ed362bb7664bf6b8fcdfe4616
9943_Clipboard01_001_pngb4f9547da89e23abf2ef7b8afdbdb123
9944_VFR_08005_Raumcon-Aufkleber_transp_kl_png692ffc23732c65e8e228459832688960
9945_Clipboard01_jpge3c2b70e75b86971b768623934a8fe2d
9946_Gemini_6_views_Gemini_7_jpg678d800a68bbc3739e5160d0b7b3efcf
9947_bildtest_jpg2aab8a373a8af0ceb4299a4a86462814
9948_VFR_08005_Raumcon-Aufkleber_RZ_jpg2834a9526e2ef4abf25b6ef4424fa36e
9949_Clipboard01_pngb44da42edae7423cf10d37cb085054ab
994_IMG_2452_jpg5f400246a6c3549d77ecc4bf7c2cf5aa
9950_Ariane5_ECA_txtfd01164b5632191b0f7720cae2f4313f
9951_raumconlexikon_jpgc3689b122da5c0b4c211b883d3007d9b
9952_raumconlexikon2_jpgac682908287fbcf919cd371084810f81
9953_raumconlexikon3_jpg751f4071a60a9533cbbf2d9b677194d3
9954_raumconlexikon4_jpg1a84d8373402226e4150caea004413c5
9955_raumconlexikon5_jpg6f7415a73278b3bde069b343f9bf040f
9956_Lexikon-Tutorial_pdf1dafd9e0dbe0e1507a018f65db0a2afc
9957_Bild-1_JPG31c438d7d1bef5ab24cc433527947531
9958_isee-3_small_gif451abd0ca15c01521535cd2e1a9f07da
9959_beta_pictoris_jpgb802e965b62023c9296a7f6236d00ce9
995_IMG_2453_jpg8851e1466faf73ee3c39f41627499a17

and 19,000+ more

EDIT: Another issue - he is not taking over the number of views to SMF. Is this feature included into the converter?
« Last Edit: February 27, 2009, 12:32:45 PM by pikarl »

ThorstenE

  • Guest
Re: [SMF Converter] Yabb 2.2
« Reply #13 on: February 27, 2009, 12:36:51 PM »
how many file are in the YaBB upload directory ($uploaddir)?

Offline pikarl

  • Semi-Newbie
  • *
  • Posts: 10
Re: [SMF Converter] Yabb 2.2
« Reply #14 on: February 27, 2009, 12:37:15 PM »
less than 100, around 11 MB.

ThorstenE

  • Guest
Re: [SMF Converter] Yabb 2.2
« Reply #15 on: February 27, 2009, 01:42:37 PM »
the converter checks different vars before inserting the data into the convert table

if (isset($yabb['uploaddir']) && !empty($message[12]) && file_exists($yabb['uploaddir'] . '/' . $message[12]))

are you sure the variable $yabb['uploaddir'] is set to the right path?

Offline hhhoagie

  • Semi-Newbie
  • *
  • Posts: 25
Re: [SMF Converter] Yabb 2.2
« Reply #16 on: February 27, 2009, 04:28:55 PM »
the yaBB converter needs a configuration file from your old YaBB:
Paths.pl
the Paths.pl contains the variables for your data dirs..

Quote
   $boardsdir = "./Boards";
   $sourcedir = "./Sources";
   $memberdir = "./Members";
   $vardir    = "./Variables";

I'll check my YaBB installation later this day, maybe I can post an example paths.pl
Well I don't have a path.pl file so how do I go about getting around this.  I have my Boards, Sources, Members, Variable, Modules, Attachments, Messages and Templates backed up and that's all I have.
Am I dead in the water?  Or is there hope for me?
SMF 2.0.4
Template Curve
No extensions

ThorstenE

  • Guest
Re: [SMF Converter] Yabb 2.2
« Reply #17 on: February 28, 2009, 02:34:52 AM »
place a "sample" paths.pl to your YaBB folder, then our converter should be able to read the old data files..

try the attached version.

Offline pikarl

  • Semi-Newbie
  • *
  • Posts: 10
Re: [SMF Converter] Yabb 2.2
« Reply #18 on: February 28, 2009, 08:26:45 AM »
the converter checks different vars before inserting the data into the convert table

if (isset($yabb['uploaddir']) && !empty($message[12]) && file_exists($yabb['uploaddir'] . '/' . $message[12]))

are you sure the variable $yabb['uploaddir'] is set to the right path?

I checked this now, the path is set correctly to the absolute directory and $yabb['uploaddir'] is set to it as well. Now I finally know what´s going wrong but I don´t have an elegant solution. In function convertStep12() in yabb22_to_smf.php the while loop is running infinitely. So he is copying YaBB´s 160 attachment files many times to SMF´s attachment directory. But I do not get why the while loop is not breaking up at this point as it should:

Code: [Select]
if (mysql_num_rows($result) < $block_size)
break;

My workaround for the moment is to set the number of loops to the number I assume to be needed regarding the block size and the total number of files in YaBB´s attachment folder.

Offline hhhoagie

  • Semi-Newbie
  • *
  • Posts: 25
Re: [SMF Converter] Yabb 2.2
« Reply #19 on: February 28, 2009, 07:00:43 PM »
place a "sample" paths.pl to your YaBB folder, then our converter should be able to read the old data files..

try the attached version.

Whoo Hoo.  That worked and looks like no errors.  Smoooooth.  thank you TE
SMF 2.0.4
Template Curve
No extensions