Upgrading from Drupal 4 to Drupal 6 - Converting Flexinode to CCK

September 25, 2009
blog author

Appno Blogger

Appnovation Coop

When I was upgrading a site from Drupal 4 to Drupal 6, I had also to convert Flexinodes to CCK nodes. Luckily, there is a module that serves this purpose, and you can find it here: http://drupal.org/project/flexiconvert. As you can see, there are 2 versions of this converter - for 4.7.x-0.3 and 5.x-0.3. I expected that it would be easier to upgrade Flexinode module v.4 to v.5 and when the module upgrades then convert Flexinode to CCK. As recommended, I CAREFULLY read the instructions in readme.txt and converted my flexinodes to CCK.

At the first glance it worked like a charm. On the second - I found out that even the new node types were nicely created, but the data itself, for image fields, was not imported (sorry, I already do not remember what exactly was lost). Another thing to mention here is to make sure you have nice flexinodes' names.

Check this: SELECT name FROM `flexinode_type` - in my case one of the names was "page + take action", and no wonder that I get SQL error during the conversion when the Converter tried to create a column name with "+" in it. So, I had so step back and try what I can do with this converter in Drupal 4. You can find the instructions at: http://drupal.org/node/113152. This is not as easy as in the version for Drupal 5 because I had to create all CCK fields manually, but when I finally run the convention - everything was converted just perfectly. Basically, if you are racking you brain trying to decide with which Drupal revision you should do the conversion, I would recommend to start with 5.x-0.3 version and see where it gets you. If it worked fine for your Flexinodes (yours and mine can be so different, right?) - you are lucky. If not – no problem, not much time is lost in trying, but it’s definitely worth it. Just go back to Drupal 4 and convert flexinodes there.