Home >Database >Mysql Tutorial >mac下修改mysql的密码_MySQL

mac下修改mysql的密码_MySQL

WBOY
WBOYOriginal
2016-06-02 08:49:551217browse

1.输入 mysql -u root mysql

2.mysql> 状态下输入 update user set password=password('新密码') where user='root';

3.mysql> 状态下输入 FLUSH PRIVILEGES;

(这个指令会让已载入记忆体的 mysql 系统资料库更新)

4.mysql> 状态下输入 quit;

每一行命令都要以分好结尾才开始执行。

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn