• I have a WordPress backup file with a .gz that was created with the wp-db-backup plugin. I am trying to restore it with PhpMyAdmin. I have followed the instructions that I find here (https://codex.www.ads-software.com/Restoring_Your_Database_From_Backup) and I am getting this error…. help:

    Error
    There is a chance that you may have found a bug in the SQL parser. Please examine your query closely, and check that the quotes are correct and not mis-matched. Other possible failure causes may be that you are uploading a file with binary outside of a quoted text area. You can also try your query on the MySQL command line interface. The MySQL server error output below, if there is any, may also help you in diagnosing the problem. If you still have problems or if the parser fails where the command line interface succeeds, please reduce your SQL query input to the single query that causes problems, and submit a bug report with the data chunk in the CUT section below:

    —-BEGIN RAW—-
    ERROR: C1 C2 LEN: 1 2 2912
    STR:

    SVN: $Id: sqlparser.lib.php 11513 2008-08-28 16:17:53Z lem9 $
    MySQL: 4.1.14
    USR OS, AGENT, VER: Win SAFARI 5.0.534
    PMA: 2.11.9.6
    PHP VER,OS: 4.3.11 FreeBSD
    LANG: en-utf-8

    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 1

Viewing 5 replies - 1 through 5 (of 5 total)
  • Silly question I know, but was the compressed backup file (somename.gz) decompressed, before you tried the import/restore ?

    Thread Starter sholt

    (@sholt)

    Pete, I did nothing to the gz file before trying to import it. Are you saying that I need to do that??

    Read the tutorial first, at:

    https://www.tamba2.org.uk/wordpress/restore/

    Note that they mention a file with a .SQL extension. If the backup has a .GZ or .TAR.GZ , etc, etc, it means the .SQL file has been compressed (zipped up if you like), so you do need to unzip it prior to importing. That said, Step 3 , part B has a dialog to “autodetect” if the file to be imported is compressed or not, so importing a compressed file

      should

    be okay.

    Also, the first line in the tutorial states

    WordPress 2.x.x uses a cache file. You MUST delete the cache or this will not appear to have worked.

    So, let us know if you have any more problems, and what method you used to do the import.

    Pete

    Thread Starter sholt

    (@sholt)

    Thanks Pete. Your advice helped. I got my database restored.

    Bob

    (@bobschecter)

    Didn’t work for me. First time I needed it, it failed. Useless plugin!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘database restore failed on upload’ is closed to new replies.