Answer the question
In order to leave comments, you need to log in
What is ROLES in PostgreSQL?
quote from https://www.digitalocean.com/community/tutorials/p...
Another assumption that Postgres makes is that for each role that has been used to login, it must create a database with the same name as the name of the role that can be accessed by that role.
Therefore, for the user we created earlier called sammy, the corresponding role will by default try to connect to the sammy database. You can create this database using the createdb command.
Answer the question
In order to leave comments, you need to log in
please explain the meaning of roles in postgres
Several useful sections about roles:
https://postgrespro.ru/docs/postgresql/9.4/user-ma...
If the databases are located on the same PostgreSQL instance , then they share the same roles. It doesn't make much sense to create separate roles for each of these databases.
You can create multiple roles in the same database. This is fine. For example, the roles of admin and regular user.
A role is a concept that combines users and user groups. That is, both users and their groups are essentially roles in PostgreSQL. Each of the roles can be assigned some access rights.
Documentation about roles
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question