Support ⇒ Upgrades :: Archives ⇒ mysql database prefix change. :: Archived ⇒ Community Forums ⇒ CPG Dragonfly™ CMS
Forum IndexUpgrades

Archived ⇒ mysql database prefix change.


I know this comes up and have read the post and the FAQ on this. I just seem to be not able to figure it out and still have problems.

I have a new install of dragonfly on my server and would like to install the old mysql data base on it. the problem is the new istall is cms_ prefix and the old is azb_ prefix.

I would love to have a step by step check of list on how to do this. seems what I ave done over and over do not work. I might not be as smart as most Sad

So how do I chang the prefix from azb_ to cms_ then how do I import it into the new database. with setting etc. what might seem simple to you is just put me in the dark ages.

Thanks Eric

www.azbaja.com
www.Fire-Fight.com

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
CMS 9.1.2.1


No need to change your database - just edit your includes/config.php with a suitable utf8 friendly editor and change the one line that has your prefix.

DonationsPro for DragonflyCMS & SMF

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):


what editor would you use? I have CuteFTP so I can edit includes/config.php file but the sql stuff has me at a loss. I hav tried the bigdump.php and it errors out. talk about pulling hairs.

I have been trying to get this done for a year now.

As always thanks.

www.azbaja.com
www.Fire-Fight.com

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
CMS 9.1.2.1


what editor would you use? I have CuteFTP so I can edit includes/config.php file but the sql stuff has me at a loss. I hav tried the bigdump.php and it errors out. talk about pulling hairs.

I have been trying to get this done for a year now.

As always thanks.

www.azbaja.com
www.Fire-Fight.com

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
CMS 9.1.2.1


I have done it with cuteftp - I would create a backup of config.php first anyway.

DonationsPro for DragonflyCMS & SMF

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):


Ok, I will give it a try in the AM any other tips on geting the file upload the azb_bbpost_text.sql file is 4.35m and for what ever reason it will not work with bigdump.php but smaller sql files have uploaded with out a problem.

Thanks
Eric

www.azbaja.com
www.Fire-Fight.com

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
CMS 9.1.2.1


hmm, I've used bigdump for files over 1GB without problems, so I'm not sure why it doesn't work for you.

DonationsPro for DragonflyCMS & SMF

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):


No luck on this...

is this corect?

Change your table prefix

If you are going to install a fresh CPG-Nuke driven website we advise that you change $prefix and $user_prefix to something of your own choosing.

If you forgot to do that, or you already have a running CPG-Nuke site, just follow these instructions...

First BACKUP your database

Then, in the below script, change "NEWPREFIX" to the new prefix you'd like to use. Save and upload this script, execute it from your browser, and run the listed SQL commands in phpMyAdmin. Once you have run these commands DELETE this file!
PHP:
<?phpdefine('CPG_NUKE', true);require_once('config.php');mysql_connect($dbhost, $dbuname, $dbpass, $dbname);$result = mysql_list_tables($dbname);while ($row = mysql_fetch_row($result) or die(mysql_error())) { $table = $row[0]; if (eregi($prefix, $table)) { echo "ALTER TABLE $row[0] RENAME ".eregi_replace($prefix,"NEWPREFIX",$table).";<br />"; }}

Then open your config.php and change the values of $prefix and $user_prefix to match the new prefix you chose in the script. Save and upload the new config.php.

Bigdump seems tp error out like this

Can't open baja2.sql.gz for import

Please, check that your dump file name contains only alphanumerical characters, and rename it accordingly, for example: baja2.sql.gz .

here is what I have now.

Table Action Records Type Collation Size Overhead
azb_bbposts_text 14,837 MyISAM utf8_general_ci 3.8 MiB -
cms_admins 1 MyISAM utf8_general_ci 4.1 KiB -
cms_autonews 0 MyISAM utf8_general_ci 1.0 KiB -
cms_banner 0 MyISAM utf8_general_ci 1.0 KiB -


still trying, you can talk to me like a 3 year old on this Smile So you can pound it into my thick head.

Thanks

www.azbaja.com
www.Fire-Fight.com

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
CMS 9.1.2.1

All times are UTC