Add to Favourites Add to Favourites    Print this Article Print this Article

I am unable to import dumps I created with the mysqldump tool bundled with the MySQL server distribution.

The problem is that mysqldump creates invalid comments like this:

-- MySQL dump 8.22
--
-- Host: localhost Database: database
---------------------------------------------------------
-- Server version 3.23.54

The invalid part of the code is the horizontal line made of dashes that appears once in every dump created with mysqldump. If you want to run your dump you have to turn it into valid MySQL. This means, you have to add a whitespace after the first two dashes of the line or add a # before it:

-- -------------------------------------------------------

or

#---------------------------------------------------------

Was this answer helpful?

Also Read