Re: Question About Roles

From: David G Johnston <david(dot)g(dot)johnston(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Question About Roles
Date: 2014-07-02 14:16:56
Message-ID: 1404310616339-5810189.post@n5.nabble.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Tom Lane-2 wrote
> Rich Shepard &lt;

> rshepard@

> &gt; writes:
>> ... my question is what do I need to do so when a user is added to the
>> system the local administrator and the group specified during the
>> createuser
>> process, she or he can be granted that group's privileges?
>
> I might be misunderstanding, but I think you're looking for GRANT/REVOKE:
>
> GRANT rolename TO newuser;

or if you want to do it as part of creating a new user:

CREATE ROLE new_management_user
[other stuff here]
IN ROLE management;

http://www.postgresql.org/docs/9.2/interactive/sql-createrole.html

--
View this message in context: http://postgresql.1045698.n5.nabble.com/Question-About-Roles-tp5810176p5810189.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message David G Johnston 2014-07-02 14:27:12 Re: How can I replace the year of the created_at column with the current year dynamically ?
Previous Message Rich Shepard 2014-07-02 14:12:06 Re: Question About Roles [ANSWERED]