pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedNo create table
5+ messages / 3 participants
[nested] [flat]
* No create table
@ 2007-07-26 15:56 Anderson Alves de Albuquerque <andersonaa@gmail.com>
0 siblings, 2 replies; 5+ messages in thread
From: Anderson Alves de Albuquerque @ 2007-07-26 15:56 UTC (permalink / raw)
To: pgsql-admin
I need to use a user that can not have permission to create table in one
BD.
I use revoke, I tray with "revoke all on database XXX to|from USERNAME;",
but I don't have success.
Could someone help me?
With revoke I only limit access in tables.
^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: No create table
@ 2007-07-27 02:41 adey <adey11@gmail.com>
parent: Anderson Alves de Albuquerque <andersonaa@gmail.com>
1 sibling, 0 replies; 5+ messages in thread
From: adey @ 2007-07-27 02:41 UTC (permalink / raw)
To: Anderson Alves de Albuquerque <andersonaa@gmail.com>; +Cc: pgsql-admin
Did your cammand fail, or did it work, but the user can still create tables?
On 7/27/07, Anderson Alves de Albuquerque <andersonaa@gmail.com> wrote:
>
>
> I need to use a user that can not have permission to create table in one
> BD.
>
> I use revoke, I tray with "revoke all on database XXX to|from
> USERNAME;", but I don't have success.
>
> Could someone help me?
>
> With revoke I only limit access in tables.
>
>
^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: No create table
@ 2007-07-27 09:03 Alvaro Herrera <alvherre@commandprompt.com>
parent: Anderson Alves de Albuquerque <andersonaa@gmail.com>
1 sibling, 2 replies; 5+ messages in thread
From: Alvaro Herrera @ 2007-07-27 09:03 UTC (permalink / raw)
To: Anderson Alves de Albuquerque <andersonaa@gmail.com>; +Cc: pgsql-admin
Anderson Alves de Albuquerque wrote:
> I need to use a user that can not have permission to create table in one
> BD.
>
> I use revoke, I tray with "revoke all on database XXX to|from USERNAME;",
> but I don't have success.
>
> Could someone help me?
You have to revoke permissions from the _schema_, not from databases.
Say,
revoke all on schema PUBLIC FROM PUBLIC;
revoke all on schema PUBLIC FROM username;
You have to remove from PUBLIC because otherwise the user will still
have permissions to create via that privilege, even if you take his own
permission away (if he had one at all actually).
--
Alvaro Herrera http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support
^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: No create table
@ 2007-07-27 14:21 Anderson Alves de Albuquerque <andersonaa@gmail.com>
parent: Alvaro Herrera <alvherre@commandprompt.com>
1 sibling, 0 replies; 5+ messages in thread
From: Anderson Alves de Albuquerque @ 2007-07-27 14:21 UTC (permalink / raw)
To: Anderson Alves de Albuquerque <andersonaa@gmail.com>; pgsql-admin
I try with "revoke all on schema PUBLIC FROM PUBLIC;", but after give GRANT
SELECT user can't use SELECT. When I use "revoke CREATE on schema PUBLIC
FROM PUBLIC;" and give GRANT SELECT user can use SELECT.
On 7/27/07, Alvaro Herrera <alvherre@commandprompt.com> wrote:
>
> Anderson Alves de Albuquerque wrote:
> > I need to use a user that can not have permission to create table in one
> > BD.
> >
> > I use revoke, I tray with "revoke all on database XXX to|from
> USERNAME;",
> > but I don't have success.
> >
> > Could someone help me?
>
> You have to revoke permissions from the _schema_, not from databases.
> Say,
>
> revoke all on schema PUBLIC FROM PUBLIC;
> revoke all on schema PUBLIC FROM username;
>
> You have to remove from PUBLIC because otherwise the user will still
> have permissions to create via that privilege, even if you take his own
> permission away (if he had one at all actually).
>
> --
> Alvaro Herrera
> http://www.CommandPrompt.com/
> PostgreSQL Replication, Consulting, Custom Development, 24x7 support
>
--
[],
^ permalink raw reply [nested|flat] 5+ messages in thread
* Re: No create table
@ 2007-07-27 14:48 Anderson Alves de Albuquerque <andersonaa@gmail.com>
parent: Alvaro Herrera <alvherre@commandprompt.com>
1 sibling, 0 replies; 5+ messages in thread
From: Anderson Alves de Albuquerque @ 2007-07-27 14:48 UTC (permalink / raw)
To: Anderson Alves de Albuquerque <andersonaa@gmail.com>; pgsql-admin
When I use revoke that you send, I revoke permission in all database. Is
there possible I use this revoke in one BD only?
On 7/27/07, Alvaro Herrera <alvherre@commandprompt.com> wrote:
>
> Anderson Alves de Albuquerque wrote:
> > I need to use a user that can not have permission to create table in one
> > BD.
> >
> > I use revoke, I tray with "revoke all on database XXX to|from
> USERNAME;",
> > but I don't have success.
> >
> > Could someone help me?
>
> You have to revoke permissions from the _schema_, not from databases.
> Say,
>
> revoke all on schema PUBLIC FROM PUBLIC;
> revoke all on schema PUBLIC FROM username;
>
> You have to remove from PUBLIC because otherwise the user will still
> have permissions to create via that privilege, even if you take his own
> permission away (if he had one at all actually).
>
> --
> Alvaro Herrera
> http://www.CommandPrompt.com/
> PostgreSQL Replication, Consulting, Custom Development, 24x7 support
>
--
.
^ permalink raw reply [nested|flat] 5+ messages in thread
end of thread, other threads:[~2007-07-27 14:48 UTC | newest]
Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2007-07-26 15:56 No create table Anderson Alves de Albuquerque <andersonaa@gmail.com>
2007-07-27 02:41 ` adey <adey11@gmail.com>
2007-07-27 09:03 ` Alvaro Herrera <alvherre@commandprompt.com>
2007-07-27 14:21 ` Anderson Alves de Albuquerque <andersonaa@gmail.com>
2007-07-27 14:48 ` Anderson Alves de Albuquerque <andersonaa@gmail.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox