Importing Sql file to new database via myPHPadmin
-
Hi there,
I’m trying to switch some of my sites to new databases that utilise PHP5 so I can (finally) upgrade to WordPress 3.2
I’ll explain one example to you, they’re basically all the same.
I exported the contents of my old database and created a new one. In myPHPadmin no matter what I do I get the following error when importing:
***
Error
SQL query:CREATE TABLE
wp_commentmeta(meta_idBIGINT( 20 ) UNSIGNED NOT NULL AUTO_INCREMENT ,
comment_idBIGINT( 20 ) UNSIGNED NOT NULL DEFAULT ‘0’,
meta_keyVARCHAR( 255 ) DEFAULT NULL ,
meta_valueLONGTEXT,
PRIMARY KEY (meta_id) ,
KEYcomment_id(comment_id) ,
KEYmeta_key(meta_key)
) ENGINE = MYISAM DEFAULT CHARSET = utf8 AUTO_INCREMENT =1;MySQL said:
#1046 – No database selected
***
I’ve done quite a bit of research online and I’ve followed all the guidelines.
I’ve removed the lines that specify the old database (didnt work).
Then I removed the text at the top that specifies what it is e.g — phpMyAdmin SQL Dump, — version 2.11.10, — http://www.phpmyadmin.net etc, (didnt work).
Finally I removed some code at the top of the sql that was suggested to me to get rid of in a different forum. Code beginning with this:SET SQL_MODE=”NO_AUTO_VALUE_ON_ZERO”; (also didnt work)
I’ve tried uploading the sql file in myPHPadmin and pasting the code into the SQL tab of the import function.
No matter what I keep on getting the above error.If someone can help me I’d really appreciate it.
Thanks in advance
Ciaran
The topic ‘Importing Sql file to new database via myPHPadmin’ is closed to new replies.