Alter user identified by values in 11g

Source: Internet
Author: User
First, the demand
In the migration of some data to the new database, the developer requirements and the original database password to keep consistent, we go to collect password trouble is also prone to error, this time how to do? The ALTER USER statement from Oracle provides a identified by values clause that allows the DBA to modify the password directly using the ciphertext stored in the database dictionary without knowing the plaintext of the password.
Second, the method
Eg: for example, test1 password is password2018, you can change the Test2 user password to password2018, or create a test3 user password for password2018
1. Query the password encryption text for Test1
Select S.spare4 from sys.user$ s where s.name = ' TEST1 ';
2. Modify the Test2 password
Alter user test2 identified by values ' S.spare4 ';
3. Create TEST3 Users
Alter user test3 identified by values ' S.spare4 ';
4. Test Test2, TEST3 users
Conn Test2/password2018;conn test3/password2018
Success
5. Create users in batches
Select ' Create user ' | | name | | ' identified by Values ' | | Spare4 | | '; ' from sys.user$ where name is like ' test% ';

Alter user identified by values in 11g

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.