How to fix the error during importing MySQL/Database through phpMyAdmin

Friday, 25 September 2015
(7 votes)

Here in this post i going to explain you how to solve the database error during importing to phpMyAdmin in only 4 simple steps;

I recently upgraded to a new hosting provider and wanted to migrate my wordpress site, Already backup my hosted files and exported database through phpMyAdmin, I'v created a different database with different details in my new server and i tried to import .SQL file to the new database. Although, when I upload it mid-way through I got this following error:

Error

SQL query:

-- --------------------------------------------------------
--
-- Table structure for table `wp_commentmeta`
--

CREATE TABLE IF NOT EXISTS `wp_commentmeta` (

`meta_id` bigint( 20 ) unsigned NOT NULL AUTO_INCREMENT ,
`comment_id` bigint( 20 ) unsigned NOT NULL DEFAULT '0',
`meta_key` varchar( 255 ) COLLATE utf8mb4_unicode_ci DEFAULT NULL ,
`meta_value` longtext COLLATE utf8mb4_unicode_ci , 
PRIMARY KEY ( `meta_id` ) ,
KEY `comment_id` ( `comment_id` ) ,
KEY `meta_key` ( `meta_key` ( 191 ) )
) ENGINE = MYISAM DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_unicode_ci AUTO_INCREMENT =14 ; 

 

So what was the issue during importing? me!? :)

Absolutely no, The problem comes from difference between MySQL Version in old server and new one (New MySQL version is 5.1.62 and old one is 5.5.45), So how to fix it?!

In 4 simple steps mentioned in below you can import you database successfully:

1) Click the "Export" tab for the database

2) Click the "Custom" radio button

3) Go the section titled "Format-specific options" and change the dropdown for "Database system or older MySQL server to maximize output compatibility with:" from NONE to MYSQL40.

4) Scroll to the bottom and click "GO".

That's all now you can import the new database through phpMyAdmin.

It would be great if you share your expieriences with blog readers in comment area.

;)


Also see:
 

ThemeForest

Is it not a great idea to follow me to be recieve my last posts? Follow me now!


7686 times

Friday, 25 September 2015

Ibrahim Jabbari

I am Ibrahim Jabbari Web Designer / Developer since 2006, This is my blog, I'll share my experiences, Useful resources and all update news from IT world with you all, I hope you enjoy surfing my blog. Connect with me on Facebook, Twitter and and Instagram.

www.ibrahimjabbari.com