How to change password of a user in Redshift database

Use the below command to change user password:

alter user username password 'valueforpassword';

Use the below command to set expiration date for password:

alter user username password 'valueforpassword' valid until '2021-12-31 23:59';
See also  How to drop a column from a table in Redshift database