Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I got a MySQL DDL file ddl.sql which I would like to import. It starts like this:

--=20MySQL=20dump=2010.11=0A--=0A--=20Host:=20localhost=20=20=20=20=
Database:=20ww=0A--=20=
------------------------------------------------------=0A--=20Server=20=

I think it is a kind of quoted printable encoding. When I try to import this via mysql testdb < ddl.sql I get the following error:

ERROR 1064 (42000) at line 1: 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 '--=20MySQL=20dump=2010.11=0A--=0A--=20Host:=20localhost=20=20=20=20=Database:=2' at line 1

Is there a way MySQL can read this kind of files? Or do I have to convert it first? Any ideas how?

share|improve this question
    
A DDL doesn't contain the data from your database. Did you expect it to contain data? You can run DDL files from DB GUI tools, but it's not SQL, so it won't run on the database itself. –  i-CONICA May 15 '14 at 10:38
    
What happened to this file? Can you get an uncorrupted copy? –  Michael Hampton May 15 '14 at 11:57
    
did you actually try something like qp-decode? –  the-wabbit May 15 '14 at 20:20

1 Answer 1

up vote 0 down vote accepted

Solution was to decode the file with qprint before importing.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.