Solution for scott users locked in Oracle11g

Source: Internet
Author: User
Modify the locked user in Oracle11g: scott. After installing Oracle10g and creating an oracle database, log on to the user scott who comes with the database and check whether the connection is

Modify the locked user in Oracle 11g: scott. After installing Oracle10g and creating an oracle database, log on with scott, the user of the database, and check whether the connection is

Modify the locked user in Oracle 11g: scott

After installing Oracle10g and creating an oracle database, you can log on to the database using scott to check whether the connection is successful.

In the cmd command, When you log on with sqlplus scott/tiger, the following message is always prompted: ERROR: ORA-28000: the account is locked.

In the cmd command prompt, you can directly log on to oracle and enter the following command:

Sqlplus/as sysdba;

Run the following command:

SQL> alter user scott account unlock;

The user has been changed to complete the unlock operation.

Next, you can set a new password for scott.

Modify scott's logon password:

SQL> alter user scott identified by grace;

Show that the user has been changed (grace is the new password)

Now, let's test whether scott/grace can successfully log on.

SQL> conn scott/grace

The connection is displayed.


Summary of Oracle Database beginners:

Enter sqlplus In the cmd command to connect to the database. The format is:

Sqlplus user name/Password

For example, sqlplus scott/tiger;

In SQL Plus, enter conn to connect to the database. The format is:

SQL> conn user name/Password

Example: conn scott/tiger;

Modify the password of a common user in SQL Plus in the following format:

Aler user Username identified by password

For example, alter user scott identified by grace;

Code for locking and unlocking users in Oracle:

SQL> alter user Username account lock; (lock)

SQL> alter user Username account unlock; (unlock)

This article permanently updates the link address:

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.