Advertisement:

Author Topic: [WIP - Converter] IPB 3.2/3.3/3.4  (Read 144026 times)

Offline emanuele

  • SMF Super Hero
  • *******
  • Posts: 14,156
  • Gender: Male
  • THERE'S JUST ME
Re: [WIP - Converter] IPB 3.2
« Reply #20 on: May 23, 2012, 01:06:59 PM »
mmm that would require a lot of work to fix...in fact the converter should parse each and every message to fix the smiley...I don't even know if the result would work.


Take a peek at what I'm doing! ;D



Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

Offline Elizabeth II

  • Jr. Member
  • **
  • Posts: 245
  • E II R
    • @Ambrosia_News on Twitter
Re: [WIP - Converter] IPB 3.2
« Reply #21 on: May 23, 2012, 01:21:13 PM »
mmm that would require a lot of work to fix...in fact the converter should parse each and every message to fix the smiley...I don't even know if the result would work.

So I guess it didnt :( So how do I fix it or remove all this??

Offline emanuele

  • SMF Super Hero
  • *******
  • Posts: 14,156
  • Gender: Male
  • THERE'S JUST ME
Re: [WIP - Converter] IPB 3.2
« Reply #22 on: May 23, 2012, 01:58:44 PM »
Let me play a bit more with the converter, and let's see...


Take a peek at what I'm doing! ;D



Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

Offline Elizabeth II

  • Jr. Member
  • **
  • Posts: 245
  • E II R
    • @Ambrosia_News on Twitter
Re: [WIP - Converter] IPB 3.2
« Reply #23 on: May 23, 2012, 02:52:18 PM »
is there anyway without re-converting? I've reorganized my board and all and I really dont wanna do it all again :(

Offline Sefket

  • Jr. Member
  • **
  • Posts: 223
Re: [WIP - Converter] IPB 3.2
« Reply #24 on: May 23, 2012, 06:06:56 PM »
I got this:

    SELECT
    m.member_id AS id_member, SUBSTRING(m.name, 1, 80) AS member_name,
    SUBSTRING(m.members_display_name, 1, 255) AS real_name, m.email AS email_address,
    SUBSTRING(m.members_pass_hash, 1, 64) AS passwd, SUBSTRING(m.members_pass_salt, 1, 8) AS password_salt,
    m.title AS usertitle, m.last_visit AS last_login,
    m.joined AS date_registered, SUBSTRING(pc.field_3, 1, 255) AS website_url,
    SUBSTRING(pc.field_3, 1, 255) AS website_title,
    SUBSTRING(pc.field_4, 1, 255) AS icq, SUBSTRING(pc.field_1, 1, 16) AS aim,
    SUBSTRING(pc.field_8, 1, 32) AS yim, SUBSTRING(pc.field_2, 1, 255) AS msn,
    SUBSTRING(pp.signature, 1, 65534) AS signature, m.ip_address AS member_ip, m.ip_address AS member_ip2, '0' AS total_time_logged_in,
    IF (m.bday_year IS NULL, '0001-01-01', IF (m.bday_year = 0 AND m.bday_month != 0 AND m.bday_day != 0, CONCAT('0004-', m.bday_month, '-', m.bday_day), CONCAT_WS('-', IF(m.bday_year <= 4, '0001', m.bday_year), IF(m.bday_month = 0, '01', IF(m.bday_month < 10, CONCAT('0', m.bday_month), m.bday_month)), IF(m.bday_day = 0, '01', IF(m.bday_day < 10, CONCAT('0', m.bday_day), m.bday_day))))) AS birthdate,
    CASE
    WHEN (m.member_group_id = '4') THEN 1
    WHEN (m.member_group_id = '2') THEN -1
    WHEN (m.member_group_id = '6') THEN 2
    ELSE 0
    END AS id_group,
    CASE
    WHEN (pc.field_5 = 'm') THEN 1
    WHEN (pc.field_5 = 'f') THEN 2
    ELSE 0
    END AS gender
    FROM `dbhidden`.members AS m
    LEFT JOIN `dbhidden`.pfields_content AS pc ON (pc.member_id = m.member_id)
    LEFT JOIN `dbhidden`.profile_portal AS pp ON (pp.pp_member_id = m.member_id)
    LIMIT 0, 500;

Caused the error:

    Unknown column 'pc.field_4' in 'field list'
« Last Edit: May 23, 2012, 07:13:31 PM by Sefket »

Offline emanuele

  • SMF Super Hero
  • *******
  • Posts: 14,156
  • Gender: Male
  • THERE'S JUST ME
Re: [WIP - Converter] IPB 3.2
« Reply #25 on: May 24, 2012, 05:33:33 AM »
is there anyway without re-converting? I've reorganized my board and all and I really dont wanna do it all again :(
Well...yes, I think a script can be created to handle this.

@Sefket
The only think I can suggest you is to open the .sql file, find:
Code: [Select]
SUBSTRING(pc.field_4, 1, 255) AS icq, SUBSTRING(pc.field_1, 1, 16) AS aim,and replace it with:
Code: [Select]
SUBSTRING(pc.field_1, 1, 16) AS aim,or remove it entirely.


Take a peek at what I'm doing! ;D



Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

Offline Sefket

  • Jr. Member
  • **
  • Posts: 223
Re: [WIP - Converter] IPB 3.2
« Reply #26 on: May 24, 2012, 08:25:49 PM »
Removed it. Got this now:

Converting members... Unsuccessful!
This query:

    SELECT
    m.member_id AS id_member, SUBSTRING(m.name, 1, 80) AS member_name,
    SUBSTRING(m.members_display_name, 1, 255) AS real_name, m.email AS email_address,
    SUBSTRING(m.members_pass_hash, 1, 64) AS passwd, SUBSTRING(m.members_pass_salt, 1, 8) AS password_salt,
    m.title AS usertitle, m.last_visit AS last_login,
    m.joined AS date_registered, SUBSTRING(pc.field_3, 1, 255) AS website_url,
    SUBSTRING(pc.field_3, 1, 255) AS website_title,
    SUBSTRING(pc.field_4, 1, 255) AS icq,
    SUBSTRING(pc.field_8, 1, 32) AS yim, SUBSTRING(pc.field_2, 1, 255) AS msn,
    SUBSTRING(pp.signature, 1, 65534) AS signature, m.ip_address AS member_ip, m.ip_address AS member_ip2, '0' AS total_time_logged_in,
    IF (m.bday_year IS NULL, '0001-01-01', IF (m.bday_year = 0 AND m.bday_month != 0 AND m.bday_day != 0, CONCAT('0004-', m.bday_month, '-', m.bday_day), CONCAT_WS('-', IF(m.bday_year <= 4, '0001', m.bday_year), IF(m.bday_month = 0, '01', IF(m.bday_month < 10, CONCAT('0', m.bday_month), m.bday_month)), IF(m.bday_day = 0, '01', IF(m.bday_day < 10, CONCAT('0', m.bday_day), m.bday_day))))) AS birthdate,
    CASE
    WHEN (m.member_group_id = '4') THEN 1
    WHEN (m.member_group_id = '2') THEN -1
    WHEN (m.member_group_id = '6') THEN 2
    ELSE 0
    END AS id_group,
    CASE
    WHEN (pc.field_5 = 'm') THEN 1
    WHEN (pc.field_5 = 'f') THEN 2
    ELSE 0
    END AS gender
    FROM `dbhhiden`.members AS m
    LEFT JOIN `dbhhiden`.pfields_content AS pc ON (pc.member_id = m.member_id)
    LEFT JOIN `dbhhiden`.profile_portal AS pp ON (pp.pp_member_id = m.member_id)
    LIMIT 0, 500;

Caused the error:

    Unknown column 'pc.field_4' in 'field list'

Offline emanuele

  • SMF Super Hero
  • *******
  • Posts: 14,156
  • Gender: Male
  • THERE'S JUST ME
Re: [WIP - Converter] IPB 3.2
« Reply #27 on: May 25, 2012, 02:42:03 AM »
Remove also
   SUBSTRING(pc.field_4, 1, 255) AS icq,


Take a peek at what I'm doing! ;D



Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

Offline Sefket

  • Jr. Member
  • **
  • Posts: 223
Re: [WIP - Converter] IPB 3.2
« Reply #28 on: May 25, 2012, 12:32:52 PM »
Yup. Now I got this:

Converting members... Unsuccessful!
This query:

    SELECT
    m.member_id AS id_member, SUBSTRING(m.name, 1, 80) AS member_name,
    SUBSTRING(m.members_display_name, 1, 255) AS real_name, m.email AS email_address,
    SUBSTRING(m.members_pass_hash, 1, 64) AS passwd, SUBSTRING(m.members_pass_salt, 1, 8) AS password_salt,
    m.title AS usertitle, m.last_visit AS last_login,
    m.joined AS date_registered, SUBSTRING(pc.field_3, 1, 255) AS website_url,
    SUBSTRING(pc.field_3, 1, 255) AS website_title,
    SUBSTRING(pc.field_8, 1, 32) AS yim, SUBSTRING(pc.field_2, 1, 255) AS msn,
    SUBSTRING(pp.signature, 1, 65534) AS signature, m.ip_address AS member_ip, m.ip_address AS member_ip2, '0' AS total_time_logged_in,
    IF (m.bday_year IS NULL, '0001-01-01', IF (m.bday_year = 0 AND m.bday_month != 0 AND m.bday_day != 0, CONCAT('0004-', m.bday_month, '-', m.bday_day), CONCAT_WS('-', IF(m.bday_year <= 4, '0001', m.bday_year), IF(m.bday_month = 0, '01', IF(m.bday_month < 10, CONCAT('0', m.bday_month), m.bday_month)), IF(m.bday_day = 0, '01', IF(m.bday_day < 10, CONCAT('0', m.bday_day), m.bday_day))))) AS birthdate,
    CASE
    WHEN (m.member_group_id = '4') THEN 1
    WHEN (m.member_group_id = '2') THEN -1
    WHEN (m.member_group_id = '6') THEN 2
    ELSE 0
    END AS id_group,
    CASE
    WHEN (pc.field_5 = 'm') THEN 1
    WHEN (pc.field_5 = 'f') THEN 2
    ELSE 0
    END AS gender
    FROM `dbhidden`.members AS m
     LEFT JOIN `dbhhiden`.pfields_content AS pc ON (pc.member_id = m.member_id)
    LEFT JOIN `dbhhiden`.profile_portal AS pp ON (pp.pp_member_id = m.member_id)
    LIMIT 0, 500;

Caused the error:

    Unknown column 'pc.field_8' in 'field list'

Offline Sefket

  • Jr. Member
  • **
  • Posts: 223
Re: [WIP - Converter] IPB 3.2
« Reply #29 on: May 25, 2012, 01:58:00 PM »
Okay, I removed that. Now here is what I get:

Converting...
Converting members...
Incomplete.
Not quite done yet!
This conversion has paused to avoid overloading your server, and hence not working properly.
Don't worry though, nothing's wrong - simply click the continue button below to start the converter from where it left off.

Edit: Seems to be going good so far.

Offline emanuele

  • SMF Super Hero
  • *******
  • Posts: 14,156
  • Gender: Male
  • THERE'S JUST ME
Re: [WIP - Converter] IPB 3.2
« Reply #30 on: May 25, 2012, 02:19:48 PM »
It's possible you don't have some instant messaging fields, remove:
SUBSTRING(pc.field_8, 1, 32) AS yim,
should do the trick.


Take a peek at what I'm doing! ;D



Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

Offline emanuele

  • SMF Super Hero
  • *******
  • Posts: 14,156
  • Gender: Male
  • THERE'S JUST ME
Re: [WIP - Converter] IPB 3.2
« Reply #31 on: May 25, 2012, 03:21:31 PM »
And here it is another try.

Things fixed:
1) the smiley are now converted from links to only the code (I hope this wont break any other image...)
2) the quotes are now properly converted to SMF format.

@Mod Mark now that this version is up, I'm working on a way to fix your smiley! ;)
« Last Edit: July 02, 2012, 07:36:05 AM by emanuele »


Take a peek at what I'm doing! ;D



Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

Offline Sefket

  • Jr. Member
  • **
  • Posts: 223
Re: [WIP - Converter] IPB 3.2
« Reply #32 on: May 25, 2012, 08:31:52 PM »
@eman - if I provide you a database for IPB 3.3, would you able to make a converter from it?

Offline phantomm

  • Sophist Member
  • *****
  • Posts: 1,063
  • Gender: Male
    • pages/smfpl/171860759503032 on Facebook
    • Polish ElkArte community
Re: [WIP - Converter] IPB 3.2
« Reply #33 on: May 26, 2012, 08:41:55 AM »
@Sefket, did you try current version? I converted my IPB 3.3.2 to SMF 2.0.2 few days ago :)
Polskie wsparcie SMF na simplemachines.org

My mods

Offline emanuele

  • SMF Super Hero
  • *******
  • Posts: 14,156
  • Gender: Male
  • THERE'S JUST ME
Re: [WIP - Converter] IPB 3.2
« Reply #34 on: May 26, 2012, 11:11:45 AM »
I have one from phantomm, but since he confirmed it was working I didn't touch it.

It seems you have indeed something different...if you want to give me the db feel free, I'll check at the differences.


Take a peek at what I'm doing! ;D



Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.

Offline Sefket

  • Jr. Member
  • **
  • Posts: 223
Re: [WIP - Converter] IPB 3.2
« Reply #35 on: May 26, 2012, 01:59:35 PM »
@Sefket, did you try current version? I converted my IPB 3.3.2 to SMF 2.0.2 few days ago :)

Oh really? Interesting. It worked with this converter?

Offline Sefket

  • Jr. Member
  • **
  • Posts: 223
Re: [WIP - Converter] IPB 3.2
« Reply #36 on: May 26, 2012, 05:34:29 PM »
I got this from 3.3.1:

Converting...

Notice: Undefined index: convert_script in /home/pitbull/public_html/smf/convert.php on line 969

Warning: Invalid argument supplied for foreach() in /home/hidden/public_html/smf/convert.php on line 972

Notice: Undefined index: convert_script in /home/hidden/public_html/smf/convert.php on line 984
Successful.
Recalculating forum statistics...
Notice: Undefined variable: result in /home/hidden/public_html/smf/convert.php on line 2491

Notice: Undefined variable: result in /home/hidden/public_html/smf/convert.php on line 2492

Notice: Undefined index: db_fetch_assoc in /home/hidden/public_html/smf/convert.php on line 1383

Fatal error: Function name must be a string in /home/hidden/public_html/smf/convert.php on line 1383

Offline Sefket

  • Jr. Member
  • **
  • Posts: 223
Re: [WIP - Converter] IPB 3.2
« Reply #37 on: May 27, 2012, 03:41:24 PM »
That part got fixed as I just restarted the convert.

After a day, I got this:

Fatal error: Wrong value type sent to the database. Integer expected. (id_pm)(convert.php-2636) in /home/hidden/public_html/smf/Sources/Subs-Db-mysql.php on line 684

Offline Sefket

  • Jr. Member
  • **
  • Posts: 223
Re: [WIP - Converter] IPB 3.2
« Reply #38 on: May 27, 2012, 05:07:12 PM »
Okay, I managed to fix it by raising the number at the end of the URL.

Now I get this:

Converting...
Converting personal messages (step 1)...
Successful.
Converting personal messages (step 2)...Duplicate entry '555-4' for key 1

Offline emanuele

  • SMF Super Hero
  • *******
  • Posts: 14,156
  • Gender: Male
  • THERE'S JUST ME
Re: [WIP - Converter] IPB 3.2
« Reply #39 on: May 28, 2012, 03:47:17 AM »
From time to time I encountered similar errors, to mitigate the problem I lowered the number of records elaborated at each step, in that last case, for example you could open ipb3_to_smf.sql, find:
Code: (find) [Select]
/******************************************************************************/
--- Converting personal messages (step 2)...
/******************************************************************************/

TRUNCATE {$to_prefix}pm_recipients;

---* {$to_prefix}pm_recipients
---{
$no_add = true;

and replace it with:
Code: [Select]
/******************************************************************************/
--- Converting personal messages (step 2)...
/******************************************************************************/

TRUNCATE {$to_prefix}pm_recipients;

---* {$to_prefix}pm_recipients 20
---{
$no_add = true;

See the 20 after ---* {$to_prefix}pm_recipients?
If you encounter again the problem try with a lower number...


Take a peek at what I'm doing! ;D



Hai bisogno di supporto in Italiano?

Aiutateci ad aiutarvi: spiegate bene il vostro problema: no, "non funziona" non è una spiegazione!!
1) Cosa fai,
2) cosa ti aspetti,
3) cosa ottieni.