Oracle忘记密码: 1.以管理员身份登录,打开dos窗口,输入 sqlplus / as sysdba 回车 2.查看当前用户和状态 select username, account_status from dba_users; 修改密码(以scott用户为例) (1)命令改密码:password 用户名 password scott (2)SQL语句修改密码: alter user 用户名 identified by 密码: 3.解锁(以scott用户为例):alter user 用户名
可以通过发出GRANT语句增加新用户:首先在数据库本机上用ROOT用户登录上MySql,然后运行命令: mysql>GRANT ALL PRIVILEGES ON *.* TO admin'@'localhost' IDENTIFIED BY 'somepass' WITH GRANT OPTION; mysql>GRANT ALL PRIVILEGES ON *.* TO 'admin'@'%' IDENTIFIED BY 'somepass' WITH GRANT OPTION; 第一句增