Return-Path: Delivered-To: apmail-ibatis-user-java-archive@www.apache.org Received: (qmail 92423 invoked from network); 26 Oct 2005 16:06:26 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 26 Oct 2005 16:06:26 -0000 Received: (qmail 42276 invoked by uid 500); 26 Oct 2005 16:06:24 -0000 Delivered-To: apmail-ibatis-user-java-archive@ibatis.apache.org Received: (qmail 42254 invoked by uid 500); 26 Oct 2005 16:06:24 -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 42243 invoked by uid 99); 26 Oct 2005 16:06:24 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 26 Oct 2005 09:06:24 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [82.109.70.229] (HELO relay01.Phones4u.Ltd) (82.109.70.229) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 26 Oct 2005 09:06:21 -0700 Received: from relay01.Phones4u.Ltd (unverified) by relay01.Phones4u.Ltd (Clearswift SMTPRS 5.0.4) with ESMTP id for ; Wed, 26 Oct 2005 17:06:00 +0100 Received: from mail01.Phones4u.Ltd ([172.19.14.183]) by relay01.Phones4u.Ltd with InterScan Messaging Security Suite; Wed, 26 Oct 2005 17:05:59 +0100 content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-MimeOLE: Produced By Microsoft Exchange V6.0.6487.1 Subject: RE: calling trim() on sql map returned strings Date: Wed, 26 Oct 2005 17:05:59 +0100 Message-ID: <84260806ABED704BA47F849163A0D31AC86270@mail01.phones4u.ltd> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: calling trim() on sql map returned strings Thread-Index: AcXaKaGAP5U09z5/TiSnfgiM/XiIaAAHQ+7Q From: "Gareth Moorst" To: X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Before acting on this e-mail or opening any attachments you are advised to = read=20 The Caudwell Holdings group of companies' disclaimer at the end of this e-m= ail. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D So it does... I hadnn't spotted that. =20 One downside of doing it that way is that I can't use select * anymore, but= suppose I'll have to live with that. Ta. -----Original Message----- From: Daniel Henrique Ferreira e Silva [mailto:dhsilva@gmail.com] Sent: 26 October 2005 13:34 To: user-java@ibatis.apache.org Subject: Re: calling trim() on sql map returned strings Hi Gareth, Doesn't Informix have a trim-like function you could apply in your query? Like: select trim(mycolumn) as mycolumn from mytable Doing that kind of stuff in the database is the best pick IMHO. Cheers, Daniel Silva. On 10/26/05, Gareth Moorst wrote: >=20 > It would appear that I didn't make myself at all clear in that last email= - it must still be too early in the day for rational thought... > > what I want to do is call trim() on all the strings I return from the db. > > -----Original Message----- > From: Gareth Moorst > Sent: 26 October 2005 10:01 > To: user-java@ibatis.apache.org > Subject: calling trim() on sql map returned strings > Hi > > All my iBatis created objects have large amounts of spaces in their strin= g properties, because that is what my informix db returns - I was just wond= ering if I need to make a custom type handler to do this for me, or is ther= e an easier way? > > Cheers > >=20 =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D Confidentiality Notice This e-mail is confidential and intended for the use of the named recipient= only. If you are not the intended recipient please notify us by telephone= immediately on +44(0)1782 600600 or return it to us by e-mail. Please the= n delete it from your system and note that any use, dissemination, forwardi= ng, printing or copying is strictly prohibited. Any views or opinions are s= olely those of the author and do not necessarily represent those of The Cau= dwell Holdings group of companies. Encryptions and Viruses Please note that this e-mail and any attachments have not been encrypted. = They may therefore be liable to be compromised. Please also note that it i= s your responsibility to scan this e-mail and any attachments for viruses. = We do not, to the extent permitted by law, accept any liability (whether i= n contract, negligence or otherwise) for any virus infection and/or externa= l compromise of security and/or confidentiality in relation to transmission= s sent by e-mail. Monitoring=20 Activity and use of The Caudwell Holdings group of companies' systems is mo= nitored to secure its effective use and operation and for other lawful busi= ness purposes. Communications using these systems will also be monitored a= nd may be recorded to secure effective use and operation and for other lawf= ul business purposes.