Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id 6EC569FBBB6 for ; Thu, 11 Oct 2007 17:13:28 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 56344-02 for ; Thu, 11 Oct 2007 17:13:07 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from fk-out-0910.google.com (fk-out-0910.google.com [209.85.128.187]) by postgresql.org (Postfix) with ESMTP id 4D6AF9FBBBF for ; Thu, 11 Oct 2007 17:13:09 -0300 (ADT) Received: by fk-out-0910.google.com with SMTP id b27so623567fka for ; Thu, 11 Oct 2007 13:13:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=y/BdEv7Vcg2Rjdz2A6I4xKEvbTR5w2KFL6uda4VDmQs=; b=KayAYHhbu3gIrSLp/jrWyV6ey2rzKSidUiQo9I8TE2Wdo3FFnAcMyXy7cCIiOQFpKdnyh5tIsDX+Y1TAAIlOnnElgzmKJXWV01o6OEmTzU/Q3+tUbFHDTdt28+hcoNumclP8+pPNvUH4H9X0ysd0mtphPnm0dbqeTM1l/n3MqmA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=T71fp36PIaIxAYFUyfm0Zp6NkZ7yAwdwSxzZq3NowqInexWcVR5SU0kMHWU6m7veTRwEOAsIYXwqkaGe4AzIbbHNG9oabQMmEXO4OYFt99Qmhjv8r6oIoZpL9qI+YEnw0lHXQ6xEJns4CUZhsitg8PTVMFzAilMGqS+z48BS4yk= Received: by 10.82.182.1 with SMTP id e1mr3900781buf.1192133586749; Thu, 11 Oct 2007 13:13:06 -0700 (PDT) Received: by 10.82.120.10 with HTTP; Thu, 11 Oct 2007 13:13:06 -0700 (PDT) Message-ID: Date: Thu, 11 Oct 2007 17:13:06 -0300 From: "Agustin Ignacio Genoves" To: "Jessica Richard" , pgsql-admin@postgresql.org Subject: Re: how to create an user with ONLY select permission and nothing else? In-Reply-To: <320881.18517.qm@web56413.mail.re3.yahoo.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <320881.18517.qm@web56413.mail.re3.yahoo.com> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200710/104 X-Sequence-Number: 27018 With this you give permission to a table GRANT SELECT ON TABLE table TO user; 2007/10/11, Jessica Richard : > 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! > >