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 A0F4452802 for ; Thu, 11 Aug 2005 06:34:12 -0300 (ADT) 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 35268-03 for ; Thu, 11 Aug 2005 09:34:10 +0000 (GMT) Received: from mail1a.your-server.co.za (mail1a.your-server.co.za [196.7.18.227]) by svr1.postgresql.org (Postfix) with ESMTP id 0F3A95282F for ; Thu, 11 Aug 2005 06:34:09 -0300 (ADT) DomainKey-Signature: a=rsa-sha1; q=dns; c=simple; s=key002; d=hetzner.co.za; b=AxmXNSp6dfuWW4OesKODfgscS4phEvjmuDdQaxt7tn/SWDPMvW5tmrLxYJi0BOyV6JDMqYjxWklxJ0Dj9b2F+qjuMz0mUYbbtEeph6OHlusJQyNb/SnOX3AnVVFqCyJy; Received: from [196.7.18.226] (helo=hetzner.co.za) by mail1a.your-server.co.za with esmtp (Exim 4.52) id 1E39Rt-0000EH-RV for pgsql-admin@postgresql.org; Thu, 11 Aug 2005 11:34:09 +0200 Received: from localhost ([127.0.0.1]) by hetzner.co.za with esmtp (Exim 4.51 (FreeBSD)) id 1E39Rt-0004F3-5l for pgsql-admin@postgresql.org; Thu, 11 Aug 2005 11:34:05 +0200 X-Virus-Scanned: Clear (ClamAV 0.86.2/1011/Tue Aug 9 11:20:28 2005) X-dk-policy: signsall:0 testing:1 X-dk-status: no signature To: pgsql-admin@postgresql.org Subject: Schema authorization after create database. From: Ian FREISLICH X-Attribution: BOFH Date: Thu, 11 Aug 2005 11:34:05 +0200 Message-Id: X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.43 tagged_above=0 required=5 tests=[AWL=-0.062, DNS_FROM_RFC_WHOIS=0.492] X-Spam-Level: X-Archive-Number: 200508/140 X-Sequence-Number: 18459 Hi I ran into this little astonishment yesterday on 7.4.8. When I create a database connected as the super user using: CREATE DATABASE foo OWNER = foo; The database is indeed owned by user foo, but the automatically created public schema is is owned by the database super user. Should this schema not be created as owned by the database owner specified in the CREATE DATABASE command? Our work around is to drop the public schema and recreate it after reconnecting as the database owner, but that seems like work I shouldn't have to do. Is this a problem or am I expecting something that I shouldn't? Ian -- Ian Freislich