pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feedgrant select on database demo to user
4+ messages / 3 participants
[nested] [flat]
* grant select on database demo to user
@ 2006-05-03 03:32 Bryce Nesbitt <bryce1@obviously.com>
0 siblings, 1 reply; 4+ messages in thread
From: Bryce Nesbitt @ 2006-05-03 03:32 UTC (permalink / raw)
To: pgsql-sql
I find myself with long lists of tables
grant select on xx_tax to user;
grant select on xx_trip to user;
grant select on xx_foo to user;
Is there a way to grant to all tables, with a single grant? I know how
to do it in mysql, but not postgres. As close as I get it:
#grant select on database demo to user
ERROR: invalid privilege type SELECT for database
--
----
Visit http://www.obviously.com/
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: grant select on database demo to user
@ 2006-05-03 04:07 Thusitha Kodikara <kthusi@yahoo.com>
0 siblings, 0 replies; 4+ messages in thread
From: Thusitha Kodikara @ 2006-05-03 04:07 UTC (permalink / raw)
To: bryce1@obviously.com; pgsql-sql
Hi,
You could easily generate a script with the list of tables and the required grant information and then run it to give the necessary grants. (The list of tables may be obtained by querying tables in 'information_schema')
Regards,
-Thusitha
-----Original Message-----
From: pgsql-sql-owner@postgresql.org [mailto:pgsql-sql-owner@postgresql.org] On Behalf Of Bryce Nesbitt
Sent: Wednesday, May 03, 2006 9:03 AM
To: pgsql-sql@postgresql.org
Subject: [SQL] grant select on database demo to user
I find myself with long lists of tables
grant select on xx_tax to user;
grant select on xx_trip to user;
grant select on xx_foo to user;
Is there a way to grant to all tables, with a single grant? I know how
to do it in mysql, but not postgres. As close as I get it:
#grant select on database demo to user
ERROR: invalid privilege type SELECT for database
--
----
Visit http://www.obviously.com/
---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match
--
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: grant select on database demo to user
@ 2006-05-03 05:07 A. Kretschmer <andreas.kretschmer@schollglas.com>
parent: Bryce Nesbitt <bryce1@obviously.com>
0 siblings, 1 reply; 4+ messages in thread
From: A. Kretschmer @ 2006-05-03 05:07 UTC (permalink / raw)
To: pgsql-sql
am 02.05.2006, um 20:32:54 -0700 mailte Bryce Nesbitt folgendes:
> I find myself with long lists of tables
>
> grant select on xx_tax to user;
> grant select on xx_trip to user;
> grant select on xx_foo to user;
>
> Is there a way to grant to all tables, with a single grant? I know how
No, but you can use a little Script, please read:
http://people.planetpostgresql.org/greg/index.php?/archives/38-guid.html#extended
HTH, Andreas
--
Andreas Kretschmer (Kontakt: siehe Header)
Heynitz: 035242/47215, D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net
=== Schollglas Unternehmensgruppe ===
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: grant select on database demo to user
@ 2006-05-06 19:46 Bryce Nesbitt <bryce1@obviously.com>
parent: A. Kretschmer <andreas.kretschmer@schollglas.com>
0 siblings, 0 replies; 4+ messages in thread
From: Bryce Nesbitt @ 2006-05-06 19:46 UTC (permalink / raw)
To: A. Kretschmer <andreas.kretschmer@schollglas.com>; pgsql-sql
A. Kretschmer wrote:
> Is there a way to grant to all tables, with a single grant? I know how
>
>
> No, but you can use a little Script, please read:
> http://people.planetpostgresql.org/greg/index.php?/archives/38-guid.html#extended
>
> HTH, Andreas
>
Thanks,
What always happens is I create a new view, or replace an old view, and
the grant step
gets forgotten. Then I get angry users who can't see the view (I can
see it, just they can't)....
-Bryce
^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2006-05-06 19:46 UTC | newest]
Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2006-05-03 03:32 grant select on database demo to user Bryce Nesbitt <bryce1@obviously.com>
2006-05-03 05:07 ` A. Kretschmer <andreas.kretschmer@schollglas.com>
2006-05-06 19:46 ` Bryce Nesbitt <bryce1@obviously.com>
2006-05-03 04:07 Re: grant select on database demo to user Thusitha Kodikara <kthusi@yahoo.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