調試Web項目的時候出現異常:
- java.sql.SQLException: ORA-28001: the password has expired
連接Oracle,以Oracle用戶登陸,輸入以下命令
- select * from dba_profiles where profile='DEFAULT' and resource_name='PASSWORD_LIFE_TIME';
- PROFILE
- ------------------------------------------------------------
- RESOURCE_NAME
- ------------------------------------------------------------
- RESOURCE_TYPE
- ----------------
- LIMIT
- ------------------------------------------------------------
- DEFAULT
- PASSWORD_LIFE_TIME
- PASSWORD
- 180
- ------------------------------------------------------------
輸入命令:
- alter profile default limit password_life_time unlimited;
- commit;
- select * from dba_profiles where profile='DEFAULT' and resource_name='PASSWORD_LIFE_TIME';
- PROFILE
- ------------------------------------------------------------
- RESOURCE_NAME
- ------------------------------------------------------------
- RESOURCE_TYPE
- ----------------
- LIMIT
- ------------------------------------------------------------
- DEFAULT
- PASSWORD_LIFE_TIME
- PASSWORD
- UNLIMITED
- ------------------------------------------------------------
改變密碼的命令
- alter user XXXUSER identified by Welcome1;
- alter user XXXUSER identified by oracle account unlock;
再次調試,問題解決
from: http://blog.csdn.net/android_robot/article/details/7598345