Hi there,
I recently switched hosts, and I made a dump of mysql and downloaded all my files via FTP from my old host. I just got done uploading my FTP files, CHMODed all the necessary files, and I'm stuck on what I should do with the mysql dump.
Could someone supply a step-by-step process on what I should do in MyPHPAdmin to restore the database & such? It would be greatly appreciated.
Thank you.
Create a new MySQL database with the same name as your old db. If your username and password isn't the same as before, create a new user with all permissions with the name/password as your old db. Then import your dump.
Thanks.
I made the database w/ the same username & password, then I went to MyPHPAdmin > SQL, and uploaded my dump.
I received this error:
Error
SQL-query :
--
--
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 '--' at line 2
Then when I go to my website, I receive this error:
Parse error: parse error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ',' or ';' in /home/htk/public_html/include/functions.inc.php on line 99
My website is here: http://hyung-taekim.org/index.php.
Any help would be great, and I don't mind giving out the username/password for further help, if necessary.
Thank you.
Quote from: bewbs on September 11, 2004, 08:36:10 PM
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 '--' at line 2[/b]
Post line 2 (or a bit more - the lines around line2.
Joachim
I'm not sure what it means by 'manual' or where to look - all I have is this attachment.
If you are using phpmyadmin to repopulate your database, you need to unzip that file, and then use phpmyadmin to import the .sql file.
Thanks!
Unfortunatly, I'm still receiving the parse error. Any advice?
Delete and re-upload your functions.inc.php file
No prevail. :-[
T_CONSTANT_ENCAPSED_STRING is called a parser token, and means any string enclosed in double or single quotes. Most probably you have a single or double quote in one of your table's fields that's causing this problem.
Use phpmyadmin to look thru your tables - look for any single or double quotes in the filename, title, keywords, etc, fields, and then remove them. Matter of fact, you should compare your db dump with what is now in your db to see if there's anything missing or possibly corrupted.