To create a database user in PostgreSQL, do:
![](https://lxadm.com/content/images/2022/09/Ekran-Resmi-2022-09-22-10.45.26.png)
Then, to create a database and assign our user to it:
![](https://lxadm.com/content/images/2022/09/Ekran-Resmi-2022-09-22-10.45.40.png)
To verify - try connect using a wrong password:
![](https://lxadm.com/content/images/2022/09/Ekran-Resmi-2022-09-22-10.45.48.png)
This is connecting with a good password:
![](https://lxadm.com/content/images/2022/09/Ekran-Resmi-2022-09-22-10.45.55.png)
To create a database user in PostgreSQL, do:
Then, to create a database and assign our user to it:
To verify - try connect using a wrong password:
This is connecting with a good password: