schema_0_9_10_grants
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revisionNext revisionBoth sides next revision | ||
schema_0_9_10_grants [2008/11/08 16:26] – created daniel | schema_0_9_10_grants [2008/11/08 17:23] – daniel | ||
---|---|---|---|
Line 3: | Line 3: | ||
This page gives some basic guidelines on how to manage a database with multiple users in a typical scenario: | This page gives some basic guidelines on how to manage a database with multiple users in a typical scenario: | ||
* One dedicated database user is the owner of the database and all its objects. This is the user that runs the initial creation script. | * One dedicated database user is the owner of the database and all its objects. This is the user that runs the initial creation script. | ||
- | * One or several groups | + | * One or several |
- | * GRANTs | + | * Access rights |
- | * Per-user account are created with CREATE USER commands | + | * Per-user account are created with //CREATE USER// commands. |
- | * user logins are inserted into the '' | + | * user logins are inserted into the '' |
- | * Users are assigned to groups with //ALTER GROUP ADD user// commands | + | * Users are assigned to groups with //GRANT role TO user// commands. |
+ | Here is a skeleton of an SQL script that grants all rights to the '' | ||
+ | <code sql> | ||
+ | -- Tables | ||
+ | GRANT SELECT, | ||
+ | | ||
+ | | ||
+ | | ||
+ | body, | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | mail, | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | tags, | ||
+ | | ||
+ | | ||
+ | | ||
+ | words | ||
+ | TO mailusers; | ||
+ | |||
+ | -- Sequences | ||
+ | GRANT SELECT, | ||
+ | | ||
+ | TO mailusers; | ||
+ | |||
+ | </ | ||
schema_0_9_10_grants.txt · Last modified: 2008/11/08 18:02 by daniel