pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Agustin Ignacio Genoves <agustingenoves@gmail.com>
To: Jessica Richard <rjessil@yahoo.com>
To: pgsql-admin@postgresql.org
Subject: Re: how to create an user with ONLY select permission and nothing else?
Date: Thu, 11 Oct 2007 17:13:06 -0300
Message-ID: <d50beba10710111313l275f00bbtcdbeefab87cb73d9@mail.gmail.com> (raw)
In-Reply-To: <320881.18517.qm@web56413.mail.re3.yahoo.com>
References: <320881.18517.qm@web56413.mail.re3.yahoo.com>

With this you give permission to a table
GRANT SELECT ON TABLE table TO user;


2007/10/11, Jessica Richard <rjessil@yahoo.com>:
> I created a test user with the following command:
>
> $ createuser test
> Shall the new role be a superuser? (y/n) n
> Shall the new role be allowed to create databases? (y/n) n
> Shall the new role be allowed to create more new roles? (y/n) n
> CREATE ROLE
>
> This user at the moment does not have permission to look at any existing
> tables, but it can create a table:
>
>
> $ psql -Utest -d postgres
> Password for user test:
>
> postgres=> create table test(x int);
> CREATE TABLE
>
>
> Two questions:
>
> 1. How do I create a user with ONLY select permission but nothing else (not
> even creating any new tables)?
>
> 2. How do I check to see what permissions a particular user currently has?
>
> I know that \z tablename can show who has what permissions on a  table, but
> it does not tell if a user has "create table" permission or not.
>
> Thanks,
> Jessica
>
>
>
>  ________________________________
> Shape Yahoo! in your own image. Join our Network Research Panel today!
>
>



view thread (4+ messages)

Message-ID: <d50beba10710111313l275f00bbtcdbeefab87cb73d9@mail.gmail.com>
Permalink:  ../d50beba10710111313l275f00bbtcdbeefab87cb73d9@mail.gmail.com/
Also on:    postgresql.org/message-id/d50beba10710111313l275f00bbtcdbeefab87cb73d9@mail.gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: agustingenoves@gmail.com, rjessil@yahoo.com
  Subject: Re: how to create an user with ONLY select permission and nothing else?
  In-Reply-To: <d50beba10710111313l275f00bbtcdbeefab87cb73d9@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

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