Show TOC

alter userLocate this document in the navigation structure

Changes a user’s password.

Syntax
alter user <user>
   set password {<new_password> | null}
   [verify password <old_password>]
   [set <password_parameter> to '<parameter_value>']
Parameters
user

Login name of the user.

new_password

New password if you are creating or changing a password.

old_password

Current user password if you use the <verify password> parameter.

parameter and parameter_value
Parameters and corresponding values you can set.
Table 1: Password Parameters
<password_parameter>

Description and <Value>

password_expiration

Number of days after which the password expires.

Zero (0) the default, indicates that the password never expires.

If a password has expired, Replication Server locks the user account and notifies the user. If you do not change the password, then you cannot log in once disconnected until the administrator resets the password. The new password must meet all the password requirements.

Passwords do not expire for any user that rs_init creates with connect source permission or the ID user. These passwords override any setting for password_expiration that you set for all users in the Replication Server. Databases, other Replication Servers, and Replication Agents use user IDs with connect source permission.

Administrators should consider setting any user that is created for replication agent or an RSI to not expire the password.

Examples
Example 1

User “louise” changes the password from “EnnuI” to “somNIfic”:

alter user louise
 set password somNIfic
 verify password EnnuI
Example 2

Change the password expiration interval of user jsmith to 60 days:

alter user jsmith
set password to newpass
set password_expiration to '60'
Usage
  • If your Replication Server uses ERSSD, you can change the ERSSD primary user password using:

    alter user <user>
    set password <new_password>

    If this user name matches the ERSSD primary user name, ERSSD updates the <rs_users> table, issues sp_password at ERSSD to change the password, and updates the configuration file line <RSSD_primary_pw_enc>.

  • Users with “sa” permission can omit the verify password clause. Other users must provide this clause in order to change their own passwords.

  • Password settings for individual users with specified alter user override any value that is set with configure replication server.

    See Password Parameters table in configure replication server.

Permissions

alter user requires "sa" permission when altering another user’s password.