Dragonfly CMS v9 ⇒ PHP-Nuke :: Archives ⇒ sql script for migration from phpnuke :: Archived ⇒ Community Forums ⇒ CPG Dragonfly™ CMS
Forum Index Switch from X to Dragonfly v9 PHP-Nuke ⇒ Archives

Archived ⇒ sql script for migration from phpnuke


Hi,
This is a nice solution and definetly more organized than phpnuke.
I would like to move from phpnuke to DragonflyCMS. My site isn't big yet ( www.dioda.ro ) but I have to move members, weblinks, one pool few articles and one simple module wich I have "developed" myself.

Are here any sql scripts for moving from phpnuke ?
I have tryed to move only the _users table but only a part of fields are the same...

10X,
Daniel

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Linux -Apache2.2.8-MySQL 4.1.22-PHP 5.2.5-CMS 9.1.1


You should backup your site and database, then run install.php and the rest should be handled automatically.

However, success may depend on how customized your nuke site is.

The alternative is to copy your nuke site to a sub-directory, make a copy of your database and use that database for the install in the sub-directory - this would safely highlight any install issues you may have.

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Ubuntu/Apache 2.2.22/MySQL 5.6.34/PHP 7.1.22/DragonFly 10.0.48.9418


Thanks for fast reply and also for contingency advices !

It seems that the install procedure is amazing well developed.
I still have 2 questions :
1. Procedure will delete old unused nuke tables ?
2. For example in standard kit I haven't found the weblinks module. The install will migrate those data also even if the table doesn't exist ?

I'll try this and I'll let you know how it went !
Regards,
Daniel

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Linux -Apache2.2.8-MySQL 4.1.22-PHP 5.2.5-CMS 9.1.1


1. no, unused tables remain intact.
2. weblinks module is a separate install in our Downloads section - backup your specific weblinks tables before doing the module install.

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Ubuntu/Apache 2.2.22/MySQL 5.6.34/PHP 7.1.22/DragonFly 10.0.48.9418


Unfortunately it failed Sad :
"INSERT INTO nuke_blocks VALUES (NULL, '', '_MENU', '', '', 'l', 1, 1, 0, '', '', 'block-CPG_Main_Menu.php', 0)
Column count doesn't match value count at row 1"

I have tryed to three times and made all combinations with table
prefixes and it already droped 11 of old tables...


Where I have to look to fix the sql clause ? Can I start it from this point or I have to restore the the production over testing environment ?

10X !
Daniel

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Linux -Apache2.2.8-MySQL 4.1.22-PHP 5.2.5-CMS 9.1.1


CREATE TABLE nuke_blocks ( bid INT(11) NOT NULL AUTO_INCREMENT, bkey VARCHAR(15) NOT NULL, title VARCHAR(60) NOT NULL, content TEXT NOT NULL, url VARCHAR(200) NOT NULL, bposition CHAR(1) NOT NULL, weight INT(11) DEFAULT '1' NOT NULL, active TINYINT(4) DEFAULT '1' NOT NULL, refresh INT(11) DEFAULT '0' NOT NULL, time VARCHAR(14) DEFAULT '0' NOT NULL, blanguage VARCHAR(30) NOT NULL, blockfile VARCHAR(255) NOT NULL, view INT(11) DEFAULT '0' NOT NULL PRIMARY KEY (bid), KEY title (title) );Check your blocks table has the above structure.

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Ubuntu/Apache 2.2.22/MySQL 5.6.34/PHP 7.1.22/DragonFly 10.0.48.9418


No, it is not.

When I have read second time the upgrade.txt I have seen there that it is specified PHP-Nuke-7.6.
I have installed 7.7 :(.

I can help to improve the upgrade script ?

I have been looking trough incude files and I haven't found the section with inserts.

Regards,
Daniel

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Linux -Apache2.2.8-MySQL 4.1.22-PHP 5.2.5-CMS 9.1.1


Knowing how little FB changes between versions, there's probably little difference, especially in the blocks table.

In any event, the table info is in 'install/sql/' and sub-directories - it is not in the usual sql file format you may be used to.

Another option for you is to do a new install in another directory using a new database - that way you will have a copy of a new DragonflyCMS table structure.

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Ubuntu/Apache 2.2.22/MySQL 5.6.34/PHP 7.1.22/DragonFly 10.0.48.9418


The installer is complaining about tables : blocks , bbranks and topics. I have tryied to modify through core, forums and news.inc but without success. In seems that it is a little more complicated than I have expcted (by the way, it looks like a profesional code - at least compared with original nuke).

Where can I ask about how sould be modified the installer ? I really would like to migrate it.

Daniel

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Linux -Apache2.2.8-MySQL 4.1.22-PHP 5.2.5-CMS 9.1.1


As I said, do a new install somewhere so you have the Dragonfly structure.

Then compare that table structure with your nuke database tables (a copy), adjust those to match Dragonfly, then run install.

Are you sure you have a standard nuke installation?

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Ubuntu/Apache 2.2.22/MySQL 5.6.34/PHP 7.1.22/DragonFly 10.0.48.9418


Thanks for support (I didn't understand from beginning but I was doing this anyway).

Look what I did :
I have droped the last 3 columns from _blocks table (expire, action, subscription).
I have added rank_max(mediumint(9)) after rank_min in table bbranks. I have dropped column topicname from table nuke_topics.
ALTER TABLE `nuke_topics` DROP `topicname`;

The installing script was running ok.
After that I have been filling next forms for final configurations. When it has to open the portal I have received the following error :

CMS Warning line 51: On /admin.php While executing query "SELECT s.uname, s.module, s.url, u.user_allow_viewonline FROM nuke_session AS s LEFT JOIN cms_users AS u ON u.username=s.uname WHERE guest=0 OR guest=2 ORDER BY s.uname" the following error occured: Unknown column 's.module' in 'field list' In: /home/dandumit/public_html/test/blocks/block-User_Info.php on line: 29

I have added 2 columns to session table.
Finally the sql script looks like this :

ALTER TABLE `nuke_blocks` DROP `expire`, DROP `action`, DROP `subscription`;
ALTER TABLE `nuke_bbranks` ADD `rank_max` MEDIUMINT( 9 ) NOT NULL AFTER `rank_min` ;
ALTER TABLE `nuke_topics` DROP `topicname`;
ALTER TABLE `nuke_session` ADD `module` VARCHAR( 30 ) NOT NULL , ADD `url` VARCHAR( 255 ) NOT NULL ;
ALTER TABLE `nuke_users` DROP `points`, DROP `last_ip`, DROP `karma`;

ALTER TABLE `nuke_users` ADD `user_group_cp` INT( 11 ) NOT NULL DEFAULT '2',
ADD `user_group_list_cp` VARCHAR( 100 ) CHARACTER SET latin1 COLLATE latin1_swedish_ci NOT NULL DEFAULT '2',
ADD `user_active_cp` TINYINT( 4 ) NOT NULL DEFAULT '1',
ADD `susdel_reason` TEXT CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL;

ALTER TABLE `nuke_blocks` DROP `expire`, DROP `subscription`;

The portal seems to run generally test.dioda.ro , I still have to do a lot of checks to do on (like language and others).


Thanks again for support !!!

Daniel

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Linux -Apache2.2.8-MySQL 4.1.22-PHP 5.2.5-CMS 9.1.1

All times are UTC