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 48A0E32C0A8 for ; Thu, 14 Oct 2004 15:24:16 +0100 (BST) 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 20618-08 for ; Thu, 14 Oct 2004 14:24:10 +0000 (GMT) Received: from wolff.to (wolff.to [66.93.249.74]) by svr1.postgresql.org (Postfix) with SMTP id 298E932C04A for ; Thu, 14 Oct 2004 15:24:11 +0100 (BST) Received: (qmail 27278 invoked by uid 500); 14 Oct 2004 14:34:32 -0000 Date: Thu, 14 Oct 2004 09:34:32 -0500 From: Bruno Wolff III To: Igor Maciel Macaubas Cc: pgsql-admin@postgresql.org Subject: Re: Database schemas: search_path Message-ID: <20041014143432.GA25803@wolff.to> Mail-Followup-To: Igor Maciel Macaubas , pgsql-admin@postgresql.org References: <001601c4b1eb$50f45fc0$6801a8c0@providerst.local> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <001601c4b1eb$50f45fc0$6801a8c0@providerst.local> User-Agent: Mutt/1.5.6i X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200410/179 X-Sequence-Number: 15172 On Thu, Oct 14, 2004 at 09:42:45 -0300, Igor Maciel Macaubas wrote: > Hi all, > > I've organized my database design in multiple schemas, and migrated my existing tables to different schemas by using a simple how-to I found in this list history. > But what I couldn't find was a way to make this schemata fully transparent to my application - which does selects directly to tables instead to schema.table. I know that I can always set the search_path environmnet variable, but I have to do it on each session. I'd like to know if there is a way to make my set search_path persistent on the database, no matter the session. > I believe that this is supported, but couldn't find out how to make it. Can someone help me? Use ALTER DATABASE to set per database defaults.