ALTER PASSWORD
Changes
a user's password.
SYNTAX

| old_password |
Current
password for user user_name. |
| new_password |
New
password for user user_name. |
| user_name |
Name
of the user whose password is being changed. |
DESCRIPTION
The ALTER
PASSWORD command changes a user's password from its current value to a
new value. This command can be used in two ways: a user can change their
current password to a new password, or the SYSADM may change the current
password of any user to a new password.
When a user
wants to change their current password to a new password, they should
use the ALTER PASSWORD old_password TO new_password form of the command.
When the SYSADM wants to change the current password of a user to a new
password, they should use the ALTER PASSWORD OF user_name TO new_password
form of the command. For security reasons, users other than the SYSADM
are not allowed to use the second form of the command.
When changing
a user's password, the old password must match the password that is stored
in the database for that user. If a user has no password and you want
to assign a password, use the NULL keyword as the old password. If you
want to delete a user's password, use the NULL keyword as the new password.
Passwords
have a maximum length of eight characters, and may contain letters, numbers,
the underscore character, and the symbols $ and #. The first character
may not be a number.
EXAMPLES
The following
example assigns password abcdef when you do not have a password.
ALTER
PASSWORD NULL TO abcdef |
The following
example changes your password from abcdef to a23456.
ALTER
PASSWORD abcdef TO a23456 |
The following
example removes your password when your password is a23456.
ALTER
PASSWORD a23456 TO NULL |
The following
example shows how the SYSADM can change the password of user John to abcdef,
regardless of the current value of the password.
ALTER
PASSWORD OF John TO abcdef |
RELATED COMMANDS
<
ALTER DATAFILE | Contents
| ALTER REPLICATION ADD REPLICATE
>
|