mysql创建用户 grant all privileges on *.* to 'username'@'%' identified by 'password'; 此语句可直接生成mysql用户,而不需要在mysql.user表中另外insert。 此语句也可用来为用户授权。 all privileges 可改为 select,update,delete等等。 *.* 可改为特定某个数据库,例如:test.*。 % 可改为 localhost, 或者特定ip。 posted on 2017-03-01 14:22 西风古道 阅读( ...) 评论( ...) 编辑 收藏 转载于:https://www.cnblogs.com/g120992880/p/6484087.html