URGENT database error please help URGENT database error please help
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

URGENT database error please help

Started by allvip, September 19, 2013, 01:37:23 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

allvip

I moved my gallery folder and domain name to a new host
ftp uploaded all the gallery folder,set permissions etc
exported my coopermine databese with phpMyAdmin first on the old host
imported the database with phpMyAdmin on new host

Error

SQL query:

-- -- Database: `gc` -- -- -------------------------------------------------------- -- -- Table structure for table `cpg15x_albums` -- CREATE TABLE IF NOT EXISTS `cpg15x_albums` ( `aid` int(11) NOT NULL AUTO_INCREMENT, `title` varchar(255) NOT NULL DEFAULT '', `description` text NOT NULL, `visibility` int(11) NOT NULL DEFAULT '0', `uploads` enum('YES','NO') NOT NULL DEFAULT 'NO', `comments` enum('YES','NO') NOT NULL DEFAULT 'YES', `votes` enum('YES','NO') NOT NULL DEFAULT 'YES', `pos` int(11) NOT NULL DEFAULT '0', `category` int(11) NOT NULL DEFAULT '0', `owner` int(11) NOT NULL DEFAULT '1', `thumb` int(11) NOT NULL DEFAULT '0', `keyword` varchar(50) DEFAULT NULL, `alb_password` varchar(32) DEFAULT NULL, `alb_password_hint` text, `moderator_group` int(11) NOT NULL DEFAULT '0', `alb_hits` int(10) NOT NULL DEFAULT '0', PRIMARY KEY (`aid`), KEY `alb_category` (`category`), KEY `moderator_group` (`moderator_group`), KEY `visibility` (`visibility[...]

MySQL said: Documentation
#1046 - No database selected



allvip

I installed a new coppermine gallery
coppermine created a new databes for the new gallery
I exported the databes and then renamed so will not overide the existing one and I get the same error
Is this a host problem?

I installed a new gallery for testing
I wanted to exported  the database of the new gallery to see if I get it right this time
but even this databes wont import - same error

phill104

I think maybe you are struggling with phpmyadmin. Don't worry, it is not the most intuitive of packages. What the error is saying is that you need to create an empty database before importing your tables. The import just imports the tables into a db you create. How that works depends on where in phpmyadmin you press the export button in the first place.
It is a mistake to think you can solve any major problems just with potatoes.

allvip

thanks . you right

my database name on the old server was gc
now I created a new databes  - named it gc but my host adds by default myhostusername_ to all the databases I creat so the databes name is my hostusername_gc
imported the databes and it worked , I can see all coppermine tables

BUT

Coppermine critical error:
Unable to connect to database !

MySQL said: Unknown MySQL server host 'mysql' (0)

allvip

can I edit something in coppermine files to accept the database with the new name name ?

allvip

my host says but its the default settings to database always comes username_prefix

BUT it is not like that on yahoo host , always just the name you tyoed for the new db with no defaul prefix

allvip


allvip

I did have to change everything in include/config.inc.php

dbserver , dbuser , dbpass and dbname ( for how has a hard time like me understanding the error :

Coppermine critical error:
Unable to connect to database !

MySQL said: Unknown MySQL server host 'mysql' (0)

I did not changed the dbserver from mysql to my new host database server

allvip

I readed the copermine docs :

http://documentation.coppermine-gallery.net/en/export.htm

100 times for last 24 hours and I forgot this step  :o