Connecting Tech Pros Worldwide Forums | Help | Site Map

permissions

Dennis Gearon
Guest
 
Posts: n/a
#1: Nov 23 '05
If I create new database objects, I have to give permissions to any
users or groups explicitly, for every object?

---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
joining column's datatypes do not match


Bruno Wolff III
Guest
 
Posts: n/a
#2: Nov 23 '05

re: permissions


On Thu, Jul 01, 2004 at 08:36:12 -0700,
Dennis Gearon <gearond@fireserve.net> wrote:[color=blue]
> If I create new database objects, I have to give permissions to any
> users or groups explicitly, for every object?[/color]

Yes. But you can write scripts that query the information_schema and
generate the SQL GRANT commands and then run them.

---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Bruno Wolff III
Guest
 
Posts: n/a
#3: Nov 23 '05

re: permissions


On Thu, Jul 01, 2004 at 14:37:52 -0700,
Dennis Gearon <gearond@fireserve.net> wrote:[color=blue]
> Bruno Wolff III wrote:
>[color=green]
> >Yes. But you can write scripts that query the information_schema and
> >generate the SQL GRANT commands and then run them.
> >[/color]
> Can you post one (with the 'gulity' object names changed to protect
> them), please?[/color]

I don't have a script handy as I don't regularly do that. I am not sure
that they would be all that useful for you anyway. The hardest part of
the script is getting the names of the objects you want to grant access
to. If you only want some of say the tables, you somehow need to generate
that list. Once you have the list, plugging the names one by one into
GRANT statements is easy. If you don't want to have the script connect
to the database for simplicity, just have it print them to a file and
run the file from psql.

---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
joining column's datatypes do not match

Dennis Gearon
Guest
 
Posts: n/a
#4: Nov 23 '05

re: permissions


Bruno Wolff III wrote:
[color=blue]
>On Thu, Jul 01, 2004 at 08:36:12 -0700,
> Dennis Gearon <gearond@fireserve.net> wrote:
>
>[color=green]
>>If I create new database objects, I have to give permissions to any
>>users or groups explicitly, for every object?
>>
>>[/color]
>
>Yes. But you can write scripts that query the information_schema and
>generate the SQL GRANT commands and then run them.
>
>
>[/color]
Can you post one (with the 'gulity' object names changed to protect
them), please?

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo@postgresql.org so that your
message can get through to the mailing list cleanly

Dennis Gearon
Guest
 
Posts: n/a
#5: Nov 23 '05

re: permissions


Bruno Wolff III wrote:
[color=blue]
>On Thu, Jul 01, 2004 at 14:37:52 -0700,
> Dennis Gearon <gearond@fireserve.net> wrote:
>
>[color=green]
>>Bruno Wolff III wrote:
>>
>>
>>[color=darkred]
>>>Yes. But you can write scripts that query the information_schema and
>>>generate the SQL GRANT commands and then run them.
>>>
>>>
>>>[/color]
>>Can you post one (with the 'gulity' object names changed to protect
>>them), please?
>>
>>[/color]
>
>I don't have a script handy as I don't regularly do that. I am not sure
>that they would be all that useful for you anyway. The hardest part of
>the script is getting the names of the objects you want to grant access
>to. If you only want some of say the tables, you somehow need to generate
>that list. Once you have the list, plugging the names one by one into
>GRANT statements is easy. If you don't want to have the script connect
>to the database for simplicity, just have it print them to a file and
>run the file from psql.
>
>
>[/color]
I wonder how phpPgAdmin is at making this easier? I think I'll install
it and see what happens.

---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
joining column's datatypes do not match

Closed Thread