Title: Database Restore Issue
Last modified: August 18, 2016

---

# Database Restore Issue

 *  Resolved [faughnan](https://wordpress.org/support/users/faughnan/)
 * (@faughnan)
 * [20 years, 10 months ago](https://wordpress.org/support/topic/database-restore-issue/)
 * I switched hosts and I am following the tutorials at [http://www.tamba2.org.uk](http://www.tamba2.org.uk)
   to back up and restore my database. I have managed to back up my database fine(
   I guess). When I go to restore it, I get an error. I’m at the part where I click
   on the SQL tab and paste the contents of the .sql file or upload it. I tried 
   both methods and I get the same error:
 * ERROR:
    SQL query:
 * CREATE TABLE `wp_categories` (
    `cat_ID` int( 4 ) NOT NULL AUTO_INCREMENT , `
   cat_name` varchar( 55 ) NOT NULL default ”, `category_nicename` varchar( 200 )
   NOT NULL default ”, `category_description` text NOT NULL , `category_parent` 
   int( 4 ) NOT NULL default ‘0’, PRIMARY KEY ( `cat_ID` ) , UNIQUE KEY `cat_name`(`
   cat_name` ) , KEY `category_nicename` ( `category_nicename` ) ) ENGINE = MYISAM
   DEFAULT CHARSET = latin1 AUTO_INCREMENT =2
 *  MySQL said: Documentation
    #1064 – You have an error in your SQL syntax. Check
   the manual that corresponds to your MySQL server version for the right syntax
   to use near ‘DEFAULT CHARSET=latin1 AUTO_INCREMENT=2’ at line 10
 * Now, I have no clue what any of this stuff means. Any help would be greatly appreciated!
 * Lindsay

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [20 years, 10 months ago](https://wordpress.org/support/topic/database-restore-issue/#post-242045)
 * When exporting your database via phpmyadmin, make sure that “Add AUTO_INCREMENT
   value” is selected.
 *  [Mark (podz)](https://wordpress.org/support/users/podz/)
 * (@podz)
 * [20 years, 10 months ago](https://wordpress.org/support/topic/database-restore-issue/#post-242057)
 * DEFAULT CHARSET=latin1
 * Open your file in notepad, or use the SCR program I mention in the guides, and
   get rid of that line above. Then the import will be fine.
 * Just do a search/replace and replace _DEFAULT CHARSET=latin1_ with nothing.
 *  Thread Starter [faughnan](https://wordpress.org/support/users/faughnan/)
 * (@faughnan)
 * [20 years, 10 months ago](https://wordpress.org/support/topic/database-restore-issue/#post-242110)
 * Yes! Thank you so much Podz!
 *  [calebcop](https://wordpress.org/support/users/calebcop/)
 * (@calebcop)
 * [20 years, 10 months ago](https://wordpress.org/support/topic/database-restore-issue/#post-242517)
 * Getting rid of that line worked for me too! Thanks Podz! Hopefully people having
   this problem will see this thread.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Database Restore Issue’ is closed to new replies.

 * In: [Installing WordPress](https://wordpress.org/support/forum/installation/)
 * 4 replies
 * 4 participants
 * Last reply from: [calebcop](https://wordpress.org/support/users/calebcop/)
 * Last activity: [20 years, 10 months ago](https://wordpress.org/support/topic/database-restore-issue/#post-242517)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
