Home  >  Article  >  Database  >  MySql 管理操作常用命令_MySQL

MySql 管理操作常用命令_MySQL

WBOY
WBOYOriginal
2016-05-31 08:46:381036browse

登陆mysql

mysql -u username -p

创建用户名配置权限,这里为该用户配置tablename表的全部权限,也可以指定

GRANT ALL PRIVILEGES ON tablename.* TO 'username'@'hostname' IDENTIFIED BY 'password';

删除用户权限,使用revoke操作

REVOKE ALL PRIVILEGES ON table.* FROM 'username'@'host';

删除一个用户

DROP USER ‘username'@'host';

 

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