Reputation: 1588
Hi, it’s weird because it always worked for me and now I keep getting an 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 ‘mysqldump: [Warning] Using a password on the command line interface can be insec’ at line 1
and I am copy and pasting the command that is in the docs:
$ docker exec -i some-mysql sh -c 'exec mysql -uroot -p"$MYSQL_ROOT_PASSWORD"' < /some/path/on/your/host/all-databases.sql
I then edit it to:
$ docker exec -i sql-db sh -c 'exec mysql -uroot -p"super_secret_pw" users' < ./source.sql
also: after $ docker ps
I get:
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
8fa9cb82332e mysql:5.7 "docker-entrypoint.s…" 20 minutes ago Up 20 minutes 0.0.0.0:3306->3306/tcp, 33060/tcp sql-db
and I get the above error. thanks for any help
Upvotes: 2
Views: 921
Reputation: 1588
So the issue was that at the top of the dump the text on line one is:
1 mysqldump: [Warning] Using a password on the command line interface can be insecure.
Upvotes: 2