Moved server, problem with the sql Moved server, problem with the sql
 

News:

CPG Release 1.6.27
change DB IP storage fields to accommodate IPv6 addresses
remove use of E_STRICT (PHP 8.4 deprecated)
update README to reflect new website
align code with new .com CPG website
correct deprecation in captcha

Main Menu

Moved server, problem with the sql

Started by h4nh4n, March 08, 2007, 09:07:59 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

h4nh4n

I am using Coppermine Photo Gallery v1.4.8 in the old webserver then I installed a new version of the gallery (1.4.10) on the new server, I try to import the old sql  to the new server and I got an error in phpmyadmin:
Error

MySQL said: Documentation
#1062 - Duplicate entry 'disk?' for key 1

I have tried to search 'disk?' but no luck, can't find it.

when I try to access to the homepage/index of the gallery it showing
While executing query "SELECT * FROM cpg_config" on 0

mySQL error: Table 'h4nh4n_copp1.cpg_config' doesn't exist


Anyone know what's the problem?

Thanks in advance :)
Artis Indonesia - Albums of Indonesian Actresses
Johan Ng - Personal Website

h4nh4n

Okay, I have fixed the problem in phpmyadmin (just compared the new one and old one).

However I still got an error msg in index, and I think its because the table names are different between two version.

for example table for banned in the old version
--
-- Table structure for table `cpg148_banned`
--

DROP TABLE IF EXISTS `cpg148_banned`;
CREATE TABLE `cpg148_banned` (
  `ban_id` int(11) NOT NULL auto_increment,
  `user_id` int(11) default NULL,
  `ip_addr` tinytext,
  `expiry` datetime default NULL,
  `brute_force` tinyint(5) NOT NULL default '0',
  PRIMARY KEY  (`ban_id`)
) TYPE=MyISAM;



and the new one like
--
-- Table structure for table `cpg_banned`
--

CREATE TABLE `cpg_banned` (
  `ban_id` int(11) NOT NULL auto_increment,
  `user_id` int(11) default NULL,
  `ip_addr` tinytext collate latin1_general_ci,
  `expiry` datetime default NULL,
  `brute_force` tinyint(5) NOT NULL default '0',
  PRIMARY KEY  (`ban_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci AUTO_INCREMENT=1 ;
Artis Indonesia - Albums of Indonesian Actresses
Johan Ng - Personal Website

Tranz

In include/config.inc.php, you will need to update the table prefix variable.

h4nh4n

thanks TranzNDance,

the problem has been solved  :D
Artis Indonesia - Albums of Indonesian Actresses
Johan Ng - Personal Website