MySQL

来自Gea-Suan Lin's Wiki
跳到导航 跳到搜索

MySQL是一套数据库软件。

常用指令

开账号顺便开权限:

GRANT ALL ON trac.* TO `trac`@`localhost` IDENTIFIED BY 'password_here';
GRANT ALL ON trac.* TO `trac`@`%` IDENTIFIED BY 'password_here';

删除(同时也会移除权限):

DROP USER 'trac'@'localhost';

只移除权限(单一数据库或是全部):

REVOKE ALL, GRANT OPTION ON trac.* FROM 'trac'@'localhost';
REVOKE ALL, GRANT OPTION FROM 'trac'@'localhost';

改密码:

SET PASSWORD = 'newPassword';

相关连结

外部链接