homepage Welcome to WebmasterWorld Guest from
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / Code, Content, and Presentation / Databases
Forum Library, Charter, Moderator: open

Databases Forum

right syntax to use near ''2009-09-01 23' at line 1? Error

5+ Year Member

Msg#: 4142421 posted 11:54 pm on May 27, 2010 (gmt 0)

I keep getting this error. I'm changing my wordpress site that was on a shared server to a dedicated server and when I try and IMPORT the database in phpmyadmin this error pops up, but its only for the wp_post part which in MY OPINION is most important.

"right syntax to use near ''2009-09-01 23' at line 1 wordpress database"

Any help or workarounds? I tried posting piece by piece but its over 89 articles on the site...:/

thanks ahead



WebmasterWorld Senior Member rocknbil us a WebmasterWorld Top Contributor of All Time 10+ Year Member

Msg#: 4142421 posted 3:29 am on May 28, 2010 (gmt 0)

Well, what little bit I can glean from that is that the date, or the datetime value, needs to be quoted.

insert into table(created) values('2009-09-01');

insert into table(created) values('2009-09-01 23:15:12');

Are you importing from a mysqldump or an exported delimited file? In the latter case, a line break in the wrong place would do it.


5+ Year Member

Msg#: 4142421 posted 11:35 pm on Jun 2, 2010 (gmt 0)

it is a mysqldump... file extention mysql.txt


5+ Year Member

Msg#: 4142421 posted 12:03 am on Jun 3, 2010 (gmt 0)

must be some issue with your export/import compatibility then. If you try to import your script to your webhoster then it is very likely that you don't have permissions to use certain mysql commands (GRAND, FILE, CREATE, DROP) depending on your hosting provider and package - you would expect a "no permission" error message here, but i have also seen "syntax error" messages in this case sometimes. you could try to export your data again, but without the "create table" and without the "drop table if exits" option and then import it again via phpmyadmin - this should work if you already have a blank wordpress installation with a compatible database @ your new hoster.

the file extension is irrelephant here.

Global Options:
 top home search open messages active posts  

Home / Forums Index / Code, Content, and Presentation / Databases
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved