vBulletin 3.6.8 pl2 -> SMF Wrong value type sent to the database

Started by jlbooker, October 08, 2011, 01:16:17 PM

Previous topic - Next topic

jlbooker

Hi all,

I'm trying to convert from an old instance of vBulletin at version 3.6.8 patch level 2, to the latest version of SMF. I just downloaded the converter today and ran it on a fresh install of SMF.

I'm getting the error:
Converting members...
Successful.
Converting administrators... Successful.
Converting categories...Wrong value type sent to the database. Integer expected. (can_collapse)

Any ideas on how to fix this?

Oldiesmann

You're using the "vBulletin 3.6 to SMF 2-0" converter from the downloads page, correct?
Michael Eshom
Christian Metal Fans

jlbooker

That's correct. The files I had after un-taring were convert.php and vbulletin36_to_smf.sql.

Oldiesmann

It appears there's a typo in the converter.

Make this change to the SQL file:

Find
Code (Line 107) Select
displayorder AS cat_order, '' AS can_collapse

Replace
displayorder AS cat_order, 0 AS can_collapse
Michael Eshom
Christian Metal Fans

jlbooker

Thanks! That fixed that error. Now I've run into this one:

Converting topics...
Successful.
Converting posts (this may take some time)...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 'ORDER BY null' at line 203

jlbooker

If a little more detail would help...

The query that's failing is:
INSERT IGNORE INTO `phpws_forums_smf`.smf_messages(`id_msg`, `id_topic`, `poster_time`, `id_member`, `subject`, `poster_name`, `poster_ip`, `id_board`, `smileys_enabled`, `body`, `poster_email`, `modified_name`, `icon`) VALUES (....<bunch of message bodies here>....) ORDER BY null

The URL this fails on is:
convert.php?step=1&substep=7&start=5500

I've tried turning on debug mode (by adding '&debug=1' to the url) It seems to be detecting this flag (I added a line of code to check..), but doesn't ever write a debug log, or output anything different to the browser.

Oldiesmann

I'm not sure what's going on with that. This appears to be the query that's causing the problem:

---* {$to_prefix}messages (update id_msg)
SELECT postid AS id_msg, username AS modified_name, dateline AS modified_time
FROM {$from_prefix}editlog
ORDER BY dateline;
---*


However, that query shouldn't be interfering with the previous one at all.

Does the SQL file from this topic work any better?
Michael Eshom
Christian Metal Fans

jlbooker

That file appears to be largely the same, but it says it's for converting to smf 1.1. I'm using smf 2.0.

I tried it anyways, but it doesn't get past converting the members:
Converting members...Unknown column 'memberName' in 'field list'

Any other ideas?

Oldiesmann

Ah. I thought that one was for 2.0. Sorry.

I'll send someone else this way who knows more about converters and see if we can figure out what's going on with that query.
Michael Eshom
Christian Metal Fans

ardnas

I had the exact same problem as the first poster, and I replaced the values as instructed and now have this error:

Converting polls...Wrong value type sent to the database. Integer expected. (id_member)

help?  Thanks!

jlbooker

A quick bump on this topic.

I'm still having the same problem. Is there anyone I can contact who might know more about this particular converter? Would paying for a premium membership be likely to get me anywhere?

neothemachine

@Oldiesmann: Why isn't the typo fixed in the official downloads? I stumbled upon the same!

EDIT: I also have a polls problem: "Converting polls...Wrong value type sent to the database. Integer expected. (expire_time)" What should I do?

Well, there seems to be an error in the sql script.
The problematic line is line 275 "IF(p.timeout = 0, 0, p.dateline + p.timeout * 86400) AS expire_time,".
The row has dateline=1078492905 and timeout=65535.
p.dateline + p.timeout * 86400 = 6740716905 which is bigger than int.
This should be set to 0 in these cases as obviously no limit is desired.
Quick fix: replace the line with: IF(p.timeout = 0, 0, IF(p.timeout > 30000, 0, p.dateline + p.timeout * 86400)) AS expire_time,


EDIT2: New error, the same as ardnas "Converting polls...Wrong value type sent to the database. Integer expected. (id_member)".
This happens when the thread doesn't exist anymore but the poll still does. Don't know when this can happen, but apparently it does.
Can be fixed easily by adding "WHERE t.threadid IS NOT NULL" after the left join in line 278.

Advertisement: