Thread Starter
Pewit
(@pewit)
The full SQL statement in the SQL backup file is
#INSERT INTO wp_eom_dates VALUES (1, 1, 2012-07-15 05:52:18, ‘2014-08-09 14:00:00’, ‘2014-08-16 16:00:00’)
There is a space between the date and time (2012-07-15 05:52:18) and yet somehow these are being interpreted as being one string in the import, hence (2012 -07 -1505 :52 :18) with no space between 15 and 05.
What delimiter should be there or is there a workaround by removing the time and leaving the date alone?
Or is there another error?
Thread Starter
Pewit
(@pewit)
The problem is some of the dates don’t have single quotes around them.
Now fixed and website back up.
Is this an error caused by the backup process or by errors in the database?
Hmm, I’m not sure to be honest.
Those are custom tables that I assume came from a plugin.
Could you look at the plugin and see if it’s create table syntax is correct?
You could also try manually doing a database dump from the server and see if that has the same issues.
I am having exactly the same problem, and it is because the MySQL database dump created by BackUpWordPress does not enclose DATETIME values in delimiters. Every other site backup or site export method I’ve tried lately (cPanel, the Duplicator plugin for WordPress, the DesktopServer Premium development environment) quotes DATETIME values.
Tom, can you please update BackUpWordPress to do the same? Based on what other backup software does, this seems to be standard practice.
Thank you,
Fred Chapman
CORRECTION
I mistakenly assumed that datetime and timestamp values were treated the same way by this plugin, but that’s not the case. I just double-checked a database backup which I created with this plugin, and datetime values are enclosed in quotes. It’s timestamp values which are not enclosed in quotes, and that’s what causes the syntax error when I try to import a database backup in phpMyAdmin.
WORKAROUND
I developed a workaround for the unquoted timestamp problem and posted it here:
http://ww.wp.xz.cn/support/topic/workaround-importing-unquoted-timestamp-values