Welcome to WebmasterWorld Guest from 54.166.220.138

Forum Moderators: open

Message Too Old, No Replies

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

     
11:54 pm on May 27, 2010 (gmt 0)

5+ Year Member



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
3:29 am on May 28, 2010 (gmt 0)

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



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.
11:35 pm on Jun 2, 2010 (gmt 0)

5+ Year Member



it is a mysqldump... file extention mysql.txt
12:03 am on Jun 3, 2010 (gmt 0)

5+ Year Member



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.
 

Featured Threads

Hot Threads This Week

Hot Threads This Month