I have a problem that I think it is something easy.
I want to connect to mysql database.
If I do the following:
mysql -uroot -premoved mydatabase
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)
But if I do:
mysql -uroot -p mydatabase
Enter password: removed
mysql>
It works!!
Why?
You need single quotes around your password.
mysql -uroot '-pabc$def' mydatabaseSee mysql password is messing up my dump for reference.