is this right?
mysql -uroot -ppassword mydb < myfile.sql.gz
No, it isn't. The right way would be
zcat myfile.sql.gz | mysql -u root -ppassword mydb
Note there can be no space between the -p
and password
if using the -p syntax, refer http://dev.mysql.com/doc/refman/5.5/en/mysql-command-options.html#option_mysql_password
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With