Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id BF4241337B8F for ; Fri, 31 Dec 2010 12:22:34 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 01563-03 for ; Fri, 31 Dec 2010 16:22:27 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from stan.prospectivdirect.com (mail.prospectiv.com [155.212.59.212]) by mail.postgresql.org (Postfix) with SMTP id 5068A133798E for ; Fri, 31 Dec 2010 12:22:27 -0400 (AST) Received: (qmail 4311 invoked by uid 510); 31 Dec 2010 16:22:23 -0000 Received: from tcapobianco@prospectiv.com by stan by uid 501 with qmail-scanner-1.20 (clamuko: 0.66. spamassassin: 2.63. Clear:RC:1(127.0.0.1):. Processed in 0.021695 secs); 31 Dec 2010 16:22:23 -0000 Received: from unknown (HELO mail.prospectiv.com) (127.0.0.1) by 0 with SMTP; 31 Dec 2010 16:22:23 -0000 Received: from 173.76.181.150 (SquirrelMail authenticated user tcapobianco@prospectiv.com) by mail.prospectiv.com with HTTP; Fri, 31 Dec 2010 11:22:23 -0500 Message-ID: <6b49785d598885ab7f8c5d3955afd74c.squirrel@mail.prospectiv.com> In-Reply-To: References: <1293747263.1650.7.camel@tony1.localdomain> Date: Fri, 31 Dec 2010 11:22:23 -0500 Subject: Re: create role From: tcapobianco@prospectiv.com To: "Gibransyah Fakhri" Cc: pgsql-sql@postgresql.org User-Agent: SquirrelMail/1.4.20-RC2 MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.91 tagged_above=-5 required=5 tests=BAYES_00=-1.9, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201012/109 X-Sequence-Number: 34945 > On 31 December 2010 05:14, Tony Capobianco > wrote: >> esave_dw=> \d members >> Did not find any relation named "members". >> esave_dw=> >> esave_dw=> \d esave.members >>                     Table "esave.members" >>       Column        |            Type             | Modifiers >> ---------------------+-----------------------------+----------- >>  memberid            | numeric                     | not null >>  etc.... >> >> How can I get this so I don't have to preface the \d with the schema >> name every time? > > Hi Tony, you should changes the default search_path for the specified > users. > http://sql-info.de/postgresql/schemas.html > take a look at practical schema usage section. > Gibransyah, That did the trick! Thanks for your help. I modified my role name from developer to dev since I already have a dev schema. Here's the steps I ran below to get it working: create role dev login; alter role dev set default_tablespace=dev; alter role dev set search_path=dev,staging, esave, support, email,public; grant usage on schema esave to dev; grant usage on schema dev to dev; grant select on members to dev; grant create on schema dev to dev; grant create on tablespace dev to dev; I am a little confused as to why I had to grant usage & create on dev to dev since it's both the dev role's default_tablespace and has a schema named after it. Either way, this corrects my issue. Thanks for your help! Tony