• Downloaded WP 1.0.2 for upgrade from b2 v0.6.1.
    Going through the WP readme file, the “Upgrading from b2 v0.6.1/v0.6.2.2 to WordPress v1.0.2:” section:
    – I backed up my database.
    – Configured wp-configure.php
    – “All you really have to do is replace all the files with newer versions and run wp-admin/upgrade.php and you should be ready to go.” -> didn’t understand this, so uploaded all files. Went to wp-admin/upgrade.php and it told me WP wasn’t installed. So I installed the program.
    – “There is also an import script at wp-admin/import-b2.php.” -> Went here next, and it gave me loads of errors:
    First wea€?re going to add excerpt, post, and password functionality…
    SQL/DB Error:
    [Duplicate column name ‘post_excerpt’]
    ALTER TABLE wp_posts ADD COLUMN post_excerpt text NOT NULL;
    SQL/DB Error:
    [Duplicate column name ‘post_status’]
    ALTER TABLE wp_posts ADD post_status ENUM(‘publish’,’draft’,’private’) NOT NULL, ADD comment_status ENUM(‘open’,’closed’) NOT NULL, ADD ping_status ENUM(‘open’,’closed’) NOT NULL, ADD post_password varchar(20) NOT NULL;
    That went well! Now let’s clean up the b2 database structure a bit…
    SQL/DB Error:
    [Can’t DROP ‘ID’. Check that column/key exists]
    ALTER TABLE wp_posts DROP INDEX ID
    One down, two to go…
    SQL/DB Error:
    [Table ‘intrinz_b2.wp_settings’ doesn’t exist]
    ALTER TABLE wp_settings DROP INDEX ID
    So far so good.
    SQL/DB Error:
    [Can’t DROP ‘post_karma’. Check that column/key exists]
    ALTER TABLE wp_posts DROP post_karma
    Almost there…
    SQL/DB Error:
    [Can’t DROP ‘ID’. Check that column/key exists]
    ALTER TABLE wp_users DROP INDEX ID
    Welcome to the family. Have fun!
    – Now my blog looks the same as when I first installed it.
    I’d just like to say the readme file for upgrading from b2 to wp is crap – I didn’t understand it and now look what’s happened. It should be step-by-step, to avoid problems like this.
    Please help me fix this? I don’t know what to do next.

Viewing 15 replies - 16 through 30 (of 39 total)
  • I too am having the same b2 import problems. Nothing i do works and to be honest it really surprises me as wordpress is meant to be the ‘official’ extension of b2…
    Seems like ill just have to start a new blog and forget about my archives… really really sucks.

    @anon – can you get to #wordpress on IRC ?
    If so, someone there may be able to help you out much quicker – just say “Hi” and shoot with your question.

    What IRC server do i connect to?
    Cant seem to find any details of it on the site.

    ok, attempted to get help on irc, with no luck.
    Ive manaully transferred my posts and comments form b2 to wordpress using the queries in the perl script above (i couldnt get the script nitself to work)
    I had a problem when importing the posts into WP, due to the post id’s being bigint(20) in b2 but only int(10) in WP. e.g. my b2 posts ids are like this 106479011873570112 (apparently caused from importing from blogger way back) … anyway….
    So – people on irc told me it should be ok to change the structure of the WP tables so that post id’s are bigint(20) to match b2.
    After doing that the import worked fine. Posts show up, and the number of comments are correct.
    However… when i click to view the comment for a post, i get the ‘Sorry, no posts matched your criteria.” error.
    I did some code searching and found the problem in the wp-blog-header.php file, around line number 201 is the following code.
    // If a post number is specified, load that post
    if (($p != ”) && ($p != ‘all’)) {
    $p = intval($p);
    $where = ‘ AND ID = ‘.$p;
    }
    Which takes my bigint(20) post ID and converts it to a normal int – which of course gives an ID that doesnt match.
    So… I dont want to go hacking the php files, cause everytime an update comes out ill have to rehack it.
    My only options i can see are to reassign all the ids and somehow hope thay match up with the comments
    OR
    export the b2 data with post ids as int(10) and once again hope that they match up wioth the comments.
    This is turning in a huge nightmare… b2 -> wp easy? No way.
    Can anyone help?
    Thanks

    There is an inconscient will to delete the memory of b2 in the WP mind. Heritage is something heavy.
    So you will never find a solution of import. It will always be considered as a minor question…
    I’m agree too with critics for support. The actual forum is a pity. Why not PHBB ? Perhaps because it was the choice of b2 support ? Another sign of heritage to erase.

    Regarding my long psot above – i have FINALLY figured out how to convert my b2 blog to wordpress and it is all working.
    Im surprised at the lack of support i received in the wordpress irc channel – where my questions went unanswered, and also the lack of support in these forms.
    I am going to write up the method i used to convert and i will post it here when done.

    @anon – Are you ever going to come back and share how you successfully upgraded with the rest of us? It’s been 20 days…This is exactly what podz was talking about. People figure it out and then don’t come back to offer assistance to others who they know are having the same problems. That’s why no progress ever seems to be made. Unfortunate.

    I’m having the same problems too. Ugh, this is frustrating.

    Can someone let me in so I can fix an upgrade for them, and see what’s going on and fix it?
    An alternate to that could be to send me a dump of the b2 mysql database with all you entries, and the version and so on.
    This is not the first time I’ve made this offer, and I hope this time someone will help me help them ??
    The email address is mail @ carthik dot net

    Renaming the b2 tables worked for me. I ran the following SQL query in phpMyAdmin:
    DROP TABLE wp_categories;
    DROP TABLE wp_comments;
    DROP TABLE wp_posts;
    DROP TABLE wp_settings;
    DROP TABLE wp_users;
    RENAME TABLE b2categories TO wp_categories;
    RENAME TABLE b2comments TO wp_comments;
    RENAME TABLE b2posts TO wp_posts;
    RENAME TABLE b2settings TO wp_settings;
    RENAME TABLE b2users TO wp_users;
    Once that completed, I ran the import-b2.php script again without any errors. Checking the blog, all my posts are there… hope this helps.

    I’ve just used the aboved mentionned for a friend and it works fine. However what I did after the DROP TABLE and RENAME TABLE, was to re-import the b2 dump in the db
    Thanks for the tip ??

    Holy crap… I’ll second (or 11th or 12th as the case may be) the motion that the b2import documentation sucks ass… but WordPress seems cool, so I guess they spend more time on building than documenting…
    That last fix worked for me as well… so here’s my steps for installing WordPress (from a PHP/MySQL idiot).
    1. Download the wp zip file.
    2. Edit the wp-config as they suggest – however when you’re defining the db_name, db_user & db_password, make sure you use the settings from your B2 installation.
    3. Leave table prefix as “wp_”.
    4. Save and upload all files.
    5. Run: /wp-admin/install.php
    6. Visit your phpMyAdmin webclient. Choose the correct database, and then click on “SQL” and do the following:
    DROP TABLE wp_categories;
    DROP TABLE wp_comments;
    DROP TABLE wp_posts;
    DROP TABLE wp_settings;
    DROP TABLE wp_users;
    RENAME TABLE b2categories TO wp_categories;
    RENAME TABLE b2comments TO wp_comments;
    RENAME TABLE b2posts TO wp_posts;
    RENAME TABLE b2settings TO wp_settings;
    RENAME TABLE b2users TO wp_users;
    click “go”
    7. Back on your site, run: wp-admin/import-b2.php
    After that, if you’re like me, your b2 posts will show up.

    i followed the instructions from the previous post and I was able to get my b2 imported successfully into Word Press. There was only one difference that I had to accommodate. I did not have a “wp_settings” table to drop. I did have a b2settings table which I did rename without issue. So far so good….I’m going to try to import my old blogger archives now….

    I also followed the above mentioned methode but on the second step i got the usual errors everbody seems to have. Now i’m watching at my page with a big fat error:
    Database error:
    [Table ‘dzinelab.wp_categories’ doesn’t exist]
    SELECT * FROM wp_categories WHERE 1=1
    Warning: Invalid argument supplied for foreach() in /home/www/dzinelab/wordpress/wp-blog-header.php on line 235
    Database error:
    [Table ‘dzinelab.wp_posts’ doesn’t exist]
    SELECT DISTINCT * FROM wp_posts WHERE 1=1 AND post_date_gmt <= ‘2004-09-10 15:43:59’ AND (post_status = “publish”) GROUP BY wp_posts.ID ORDER BY post_date DESC LIMIT 10
    Database error:
    [Table ‘dzinelab.wp_posts’ doesn’t exist]
    SELECT DISTINCT YEAR(post_date) AS year, MONTH(post_date) AS month, count(ID) as posts FROM wp_posts WHERE post_date < ‘2004-09-10 17:43:31’ AND post_status = ‘publish’ GROUP BY YEAR(post_date), MONTH(post_date) ORDER BY post_date DESC
    Indeed, table wp_posts doesn’t exist in my DB. I was under the impression WP created that when uploading?
    Now i can create the table manually but that’s all i’m capable off: i’m a msql idiot. I don’t know what settings i have to set.
    Or is there some other way i can get rid of the error so i can atleast import my b2 entries by hand (copy – paste)?

Viewing 15 replies - 16 through 30 (of 39 total)
  • The topic ‘Upgrading from b2 to WP problems’ is closed to new replies.