Відмінності між версіями «Mysql»
Перейти до навігації
Перейти до пошуку
| Рядок 29: | Рядок 29: | ||
If your MySQL client/server version is a 5.6.x a way to avoid the WARNING message are using the | If your MySQL client/server version is a 5.6.x a way to avoid the WARNING message are using the | ||
mysql_config_editor tools: | mysql_config_editor tools: | ||
| − | mysql_config_editor set --login-path=local --host=localhost --user=username --password | + | mysql_config_editor set --login-path=local --host=localhost --user=username --password |
| − | mysql --login-path=local -e "statement" | + | mysql --login-path=local -e "statement" |
Remember that the --login-path has to come before all other arguments. | Remember that the --login-path has to come before all other arguments. | ||
I was trying mysqldump --tables --login-path=local and getting the error unknown variable 'login-path=local' | I was trying mysqldump --tables --login-path=local and getting the error unknown variable 'login-path=local' | ||
Поточна версія на 17:55, 12 липня 2018
Что нужно настроить в mySQL сразу после установки
Встановлення прав
GRANT ALL PRIVILEGES ON *.* TO user@'%' IDENTIFIED BY '1'; flush privileges;
Швидкий дамп та швидке розгортання
SELECT * INTO OUTFILE '/tmp/result.txt' FROM <table name> LOAD DATA INFILE '/tmp/result.txt' INTO TABLE <table name>
Значення по замовчуванню
FIELDS TERMINATED BY '\t' ENCLOSED BY ESCAPED BY '\\' LINES TERMINATED BY '\n' STARTING BY
Шпоргалка по востановлении баз и таблиц
щоб уникнути повідомлення mysql: [Warning] Using a password on the command line interface can be insecure.
If your MySQL client/server version is a 5.6.x a way to avoid the WARNING message are using the mysql_config_editor tools:
mysql_config_editor set --login-path=local --host=localhost --user=username --password mysql --login-path=local -e "statement"
Remember that the --login-path has to come before all other arguments. I was trying mysqldump --tables --login-path=local and getting the error unknown variable 'login-path=local'