Return-Path: Delivered-To: apmail-ibatis-user-java-archive@www.apache.org Received: (qmail 14723 invoked from network); 11 Mar 2006 11:18:16 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 11 Mar 2006 11:18:16 -0000 Received: (qmail 49778 invoked by uid 500); 11 Mar 2006 11:18:16 -0000 Delivered-To: apmail-ibatis-user-java-archive@ibatis.apache.org Received: (qmail 49285 invoked by uid 500); 11 Mar 2006 11:18:13 -0000 Mailing-List: contact user-java-help@ibatis.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user-java@ibatis.apache.org Delivered-To: mailing list user-java@ibatis.apache.org Received: (qmail 49266 invoked by uid 99); 11 Mar 2006 11:18:13 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 11 Mar 2006 03:18:13 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: neutral (asf.osuosl.org: local policy) Received: from [195.121.247.10] (HELO smtp19.wxs.nl) (195.121.247.10) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 11 Mar 2006 03:18:12 -0800 Received: from [10.0.0.150] (ip54539330.speed.planet.nl [84.83.147.48]) by smtp19.wxs.nl (iPlanet Messaging Server 5.2 Patch 2 (built Jul 14 2004)) with ESMTP id <0IVY00BFUNDQOJ@smtp19.wxs.nl> for user-java@ibatis.apache.org; Sat, 11 Mar 2006 12:17:50 +0100 (CET) Date: Sat, 11 Mar 2006 12:17:50 +0100 From: Beemsterboer Software Subject: Re: declarative - db schema In-reply-to: <44128ECB.3050403@pandora.be> To: user-java@ibatis.apache.org Message-id: <4412B1DE.3040400@beemsterboer-software.nl> MIME-version: 1.0 Content-type: text/plain; charset=ISO-8859-1; format=flowed Content-transfer-encoding: 7BIT User-Agent: Thunderbird 1.5 (Windows/20051201) References: <441282CA.1060104@gmail.com> <441283DB.3050203@pandora.be> <44128ECB.3050403@pandora.be> X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N This has been described in the DevGuide, refer to: "Simple Dynamic SQL Elements". In my previous project, I read the schema name from a properties file and passed it to the SqlMap statement via a parameter map. Greetings, Hans. Sven Boden wrote: > There's no "defaultSchema=name" in iBatis. So that's not possible, I > also don't think it's in the JDBC spec. The closest you can get for > the moment is putting the default schema in a properties file: > > schema=yourschema > > And then in the SqlMap use schema's explicitly as: > > select * > from ${schema}.table > > In your build procedure you can retrieve the properties for the > specific environment you're building for. > > Regards, > Sven > > Gianluca Gaiotto wrote: > >> Thanks for your immediate reply. >> But what I am trying to discover is which is (if exists!) the >> tag (in the sql map config xml file) for expressing >> the default schema. >> And I don't want let the connection parameters determine which schema >> to use, just because in our database environment we could have >> different schemas per single connection. >> >> -Gianluca >> >> >> Sven Boden wrote: >> >>> Use property files... look at e.g. >>> http://www.mail-archive.com/user-java@ibatis.apache.org/msg02598.html >>> >>> Regards, >>> Sven >> >> >> >> > > >