日期:2014-05-16  浏览次数:20759 次

无法给mysql数据库添加用户
大家帮忙看看这是哪出错了
     
        grant   all   on   depot_development.*   to   'dave '@ 'localhost ';
错误提示:error   1133   can 't   find   any   matching   row   in   the   user   table

我想这应该是没有dave这个用户,因为我已经建了depot_development这个数据库

但我不知道该怎么添加用户,希望能说详细点!

谢谢

------解决方案--------------------
你这个情况是数据库里没有这个用户。
添加用户,同时分配权限:
grant all on depot_development.* to 'dave '@ 'localhost ' identified by 'password ';
其中password为该用户的密码
------解决方案--------------------
grant all privileges on depot_development.* to 'dave '@ 'localhost ';