1

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?

Witek
  • 1,433
  • 3
  • 14
  • 16
  • 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`](http://manpages.ubuntu.com/manpages/dapper/man1/qp-decode.1.html)? – the-wabbit May 15 '14 at 20:20

1 Answers1

0

Solution was to decode the file with qprint before importing.

Witek
  • 1,433
  • 3
  • 14
  • 16