1.运行 cmd.exe;
2.输入 sqlplus / as sysdba,以系统管理员(sysdba)身份连接数据库,进行数据库管理操作。
3.连接成功后执行
alter user identityName identified by password; —–修改密码 alter user identityName account unlock; —–解锁 alter user identityName account lock; —–加锁 identityName:需要修改的用户; password:新设密码;
完成
PS: oracle 11g用户的解锁与加锁(hr模式)
SQL> conn sys/sys as sysdba Connected. SQL> show user USER is "SYS" SQL> alter user hr account unlock;(解锁) User altered. SQL> alter user hr identified by *password*;(更改密码,这一步是必需的,否则hr模式还是不能使用的) User altered. 到这里hr模式就可以使用了,试试: SQL> conn hr/*password* Connected. SQL> show user USER is "HR" ---------------------------------- 相反的 SQL> alter user hr account lock;(上锁) User altered. SQL> alter user hr password expire;(密码失效) User altered. SQL> conn hr/*password* ERROR: ORA-28000: the account is locked Warning: You are no longer connected to ORACLE.
大家学会了吗?可以自己动手尝试一下。
相关推荐:
以上就是Oracle 11g用户修改密码及加锁解锁方法教程的详细内容,更多请关注php中文网其它相关文章!
……