Title: SQL query error when importing database backup
Last modified: August 19, 2016

---

# SQL query error when importing database backup

 *  Resolved [Christiaan](https://wordpress.org/support/users/christiaan/)
 * (@christiaan)
 * [18 years, 1 month ago](https://wordpress.org/support/topic/sql-query-when-importing-database-backup/)
 * I’ve dropped all my tables and was trying to re-import my database backup but
   I get the following error:
 * > Error
   >  SQL query:
   > #
   >  # Data contents of table `wp_email_list` # INSERT INTO `wp_email_list` VALUES(
   > 1, ‘myemail@mac.com’, 1, 2005 -04 -3008 :10 :12, ‘2005-04-30 08:10:12’ ) ;
   > MySQL said:
   > #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 ’08:10:12, ‘2005-
   > 04-30 08:10:12′)’ at line 1

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

 *  Thread Starter [Christiaan](https://wordpress.org/support/users/christiaan/)
 * (@christiaan)
 * [18 years ago](https://wordpress.org/support/topic/sql-query-when-importing-database-backup/#post-762932)
 * Turns out the WordPress Database Backup plugin definitely did not use correct
   syntax when backing up. Had to manually add some single quotes.
 * Pays to stick with phpMyAdmin it seems.
 *  [crenwelge](https://wordpress.org/support/users/crenwelge/)
 * (@crenwelge)
 * [17 years, 7 months ago](https://wordpress.org/support/topic/sql-query-when-importing-database-backup/#post-763029)
 * Hi Christiann,
 * I’m getting the same problem when trying to import my backup into an empty database:
 * > SQL query:
   >  # # Data contents of table `wp_categories` # INSERT INTO `wp_categories`
   > VALUES ( 1, ‘Uncategorized’, ‘uncategorized’, ‘, 0, 0, 0, 0, 0) ; INSERT INTO`
   > wp_categories` VALUES (2, ‘Unusual ‘, ‘unusual ‘, ‘, 0, 2, 0, 0, 0 ) ; MySQL
   > said: #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 ‘Unusual’, ‘unusual’,‘,
   > 0, 2, 0, 0, 0)’ at line 1
 * I’m using Version 1.7 of database backup, phpMyAdmin 2.9.0 and WordPress 2.1.3.
   What software did you use to add the single quotes to your database backup and
   where are they placed?

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

The topic ‘SQL query error when importing database backup’ is closed to new replies.

## Tags

 * [sql-query](https://wordpress.org/support/topic-tag/sql-query/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 2 replies
 * 2 participants
 * Last reply from: [crenwelge](https://wordpress.org/support/users/crenwelge/)
 * Last activity: [17 years, 7 months ago](https://wordpress.org/support/topic/sql-query-when-importing-database-backup/#post-763029)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
