X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 6C4DC3CD0BF for ; Sun, 26 Dec 2004 07:26:49 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 36804-10 for ; Sun, 26 Dec 2004 07:26:43 +0000 (GMT) Received: from mx.nsu.ru (mx.nsu.ru [212.192.164.5]) by svr1.postgresql.org (Postfix) with ESMTP id 38F053CD0D6 for ; Sun, 26 Dec 2004 07:26:43 +0000 (GMT) Received: from land6.land7.nsu.ru ([193.124.213.206] helo=land7.nsu.ru) by mx.nsu.ru with esmtp (Exim 4.34) id 1CiSxH-0002Nk-Gb; Sun, 26 Dec 2004 13:36:43 +0600 Received: from lexx.land7.nsu.ru ([193.124.217.215]) by land7.nsu.ru with esmtp (Exim 3.35 #1 (Debian)) id 1CiSok-0000ES-00; Sun, 26 Dec 2004 13:27:54 +0600 Date: Sun, 26 Dec 2004 13:41:22 +0600 From: lexx@gorodok.net X-Mailer: The Bat! (v1.52f) UNREG / CD5BF9353B3B7091 Reply-To: lexx@gorodok.net X-Priority: 3 (Normal) Message-ID: <942074187.20041226134122@gorodok.net> To: Bruno Wolff III Cc: pgsql-admin@postgresql.org Subject: Re: database permissions:how to create read only user for db In-Reply-To: <20041225162007.GA28018@wolff.to> References: <1655106625.20041225155456@gorodok.net> <20041225162007.GA28018@wolff.to> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.178 tagged_above=0 required=5 tests=NO_REAL_NAME X-Spam-Level: X-Archive-Number: 200412/239 X-Sequence-Number: 15825 >> Hello all. >> >> Please help, >> are there any way to set some (ex. deny creating tables) privileges on database (not for databases objects)? >> >> I want crant full access to one user (let say "adminuser" for database "testdb") and make some others (read only) users, >> who can read only (do SELECT from "testdb" tables), but not CREATE tables or some database objects. >> >> As I know CRANT command allows only set privileges for database objects but not for databases. BWI> You can write scripts that will set access for all existing objects in BWI> a database. Objects created in the future will not automatically get the BWI> same access rights. It mnay be possible to simplify granting rights by BWI> using 'public' to give select access, if all users get at least select access. I see what you mean, but I want set access rights to database, not for database objects, I want to deny some users to create tables in database, but permit read values of existing tables. How to permit various access to tables I know, it's simlpy with `GRANT [..] ON TABLE ..', but I don't know how to deny creating new tables, and I think it's not possible with PostgreSQL, because as I can understand, GRANT don't support such ability for DATABASE. Am I right? will be very fine if I'm mistaken.. THanks. /lexx/