Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dhhrM-0007Yc-El for pgsql-admin@arkaria.postgresql.org; Tue, 15 Aug 2017 19:50:40 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1dhhrL-0002va-Rk for pgsql-admin@arkaria.postgresql.org; Tue, 15 Aug 2017 19:50:39 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dhhrK-0002rs-Pe for pgsql-admin@postgresql.org; Tue, 15 Aug 2017 19:50:38 +0000 Received: from resqmta-po-08v.sys.comcast.net ([2001:558:fe16:19:96:114:154:167]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dhhrF-00066n-Bh for pgsql-admin@postgresql.org; Tue, 15 Aug 2017 19:50:38 +0000 Received: from resomta-po-12v.sys.comcast.net ([96.114.154.236]) by resqmta-po-08v.sys.comcast.net with ESMTP id hhr8ddstlEFlKhhr8d5v3i; Tue, 15 Aug 2017 19:50:26 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; s=q20161114; t=1502826626; bh=fHFq6wDpE1SZe1bNpAmzrqJENzHgnOacuKLxO9CBa0s=; h=Received:Received:Received:From:To:Subject:Date:Message-ID: MIME-Version:Content-Type; b=iB5n56czOqDEFxzjwWGrpHBlbRGWY8Vfjy9UmzO6hiyV+ExC9MYIAYgFI4f85Gjts sJICYbN8n1week9AxAMom27qN/5WIgjDM1XSR6693HZUs7OxWW43Ucov1Lf6OR3ho3 UTRpaeCNJqXWGkAdzeXR+rZ5kwA0G2u0Vam8tp+EtOOVdBEJodExXtlcYEUZpxMK1t obfyJ688wF9ueknB7sUyFE+IpEsV0On+7tuudrzVTdcBfv7i3MONWT+37FK4Lwul3I RzlUt81JmAB69LT0r93/EfCHE7GNJiMF6Es+TZiTXIFh6M8zkLKfJxNNqtaAEYHS0t URdbDwdPK1bYA== Received: from jsievers.comcast.net ([12.30.159.20]) by resomta-po-12v.sys.comcast.net with SMTP id hhqvdF1r7cQv5hhqxdq6HG; Tue, 15 Aug 2017 19:50:24 +0000 Received: from jsievers.enova.com (localhost [127.0.0.1]) by jsievers.comcast.net (Postfix) with ESMTP id 006ED26005E; Tue, 15 Aug 2017 14:50:12 -0500 (CDT) From: Jerry Sievers To: Keith Cc: Don Seiler , pgsql-admin Subject: Re: CREATE ANY TABLE privileges, etc References: Date: Tue, 15 Aug 2017 14:50:12 -0500 In-Reply-To: (keith@keithf4.com's message of "Tue, 15 Aug 2017 10:08:29 -0400") Message-ID: <878tik4nm3.fsf@jsievers.enova.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-CMAE-Envelope: MS4wfHabEM5Jp3po6/Q5OTJbim0qpTXdE8t2rgz+HJNmJXMXK0fzvDnGVODJfzZqgOcuA3scqYQd5BQP+ZyindixGoBxxYWwJ2rmIiNWMxXjf6gqRc+AYcqi YEKdRT5IQvFeimYb/B8wQm2caNNWuKyMRaZizb547seOM1rW+YoJy86N5JNDZz6dz6+DUTOUuZ8xoeIun3iewDAsKLqxjxaUU4CUbf+ntLrFnmKysMdvTBwm mzIAOchmkzoMX0KtDgfCog== List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-admin Precedence: bulk Sender: pgsql-admin-owner@postgresql.org Keith writes: > On Tue, Aug 15, 2017 at 9:15 AM, Don Seiler wrote: > > Good morning, > > I've had a request to create a user that can create tables and > schemas anywhere in this dev database. I know I could just make > that user a SUPERUSER but wondering if there's anything short of > that that seems more responsible. Again, this would only be in > DEV so I'm not nearly as concerned giving them a superuser, > assuming they haven't shown a track record of reckless behavior. > > I'm thinking of privileges like Oracle's CREATE ANY TABLE, etc. > vs granting them the DBA role. > > Don. > > -- > Don Seiler > www.seiler.us > > > Easiest thing would be to grant ownership of that database to the > user. That won't grant privileges to any existing objects, but will > allow new schemas to be made by that user, which will in turn allow > objects to be made in those schema that user creates. Hmmm? Often DB objects will be owned by whichever owner role... Thus, granting that role to some other user does indeed give that user full access to same objects as per whatever grants are established on them to the owner. By default, owner has all privileges but this can be changed. HTH > Otherwise, there is the GRANT CREATE ON DATABASE ... command which > will essentially do the same thing and allow schemas to be created. > > https://www.postgresql.org/docs/9.6/static/sql-grant.html > > Keith > > -- Jerry Sievers Postgres DBA/Development Consulting e: postgres.consulting@comcast.net p: 312.241.7800 -- Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-admin