How to change an Oracle password temporarily?
In Oracle it is possible to change a password temporarily. This can be useful for DBAs who wish to act as a different user.
SQL> select username,password from dba_users where username='SCOTT';
Save the hash of the password somewhere safe. Then change it …
SQL> alter user scott identified by tmppassword;
Login with the credentials: scott/tmppassword, then after doing your work change the password back by using an undocumented feature called “by values”
SQL> alter user scott identified by values 'F894844C34402B67';