postgres reset password for user code example

Example 1: mysql change user password

ALTER USER 'user-name'@'localhost' IDENTIFIED BY 'NEW_USER_PASSWORD';FLUSH PRIVILEGES;

Example 2: reset postgres password windows

Backup the pg_hba.conf file by copying it.
Edit the pg_dba.conf, change `METHOD` to 'trust'
Restart the PostgreSQL server.
psql -U postgres.
ALTER USER postgres WITH PASSWORD 'new_password';
Restore the pg_dba.conf file.
Restart the PostgreSQL server.

Example 3: what is default mysql database password in linux

$ sudo apt install mysql-server
$ sudo cat /etc/mysql/debian.cnf

Example 4: reset password postgres ubuntu

\password sde