scott account locked in SQL Plus

Viewed 80374

When I am trying to logging to Oracle Sql plus by entering 'scott' as username and 'tiger' as password, it shows 'the account is locked'. How to unlock 'scott' account. The screen shot of SQL Plus CLI is given below.

The screen shot is given below

6 Answers

You can use below steps to account unlock

SQL> select USERNAME,ACCOUNT_STATUS from dba_users where username='SCOTT';

USERNAME ACCOUNT_STATUS


SCOTT LOCKED

SQL> alter user SCOTT account unlock;

User altered.

SQL> select USERNAME,ACCOUNT_STATUS from dba_users where username='SCOTT';

USERNAME ACCOUNT_STATUS


SCOTT OPEN

SQL> conn SCOTT/SCOTT Connected. SQL>

1.copy oracle path C:\oraclexe\app\oracle\product\11.2.0\server\rdbms\admin\scott.sql

2.Connect with sys as sysdba

3.Then paste in prompt-> @C:\oraclexe\app\oracle\product\11.2.0\server\rdbms\admin\scott.sql

4.then connect with System user.

5.alter user scott account unlock;

6.alter user scott identified by tiger;

Related