Re: How to define alias in

2009-03-27 Thread Brandon Goodin
No problem. I'm glad it worked out for you. Brandon On Fri, Mar 27, 2009 at 11:58 AM, Jasmin Mehta wrote: > > alias in SQL will work, Sorry I overlooked the SQL change earlier in first > posting. And just saw the table column name in resultMap. I apologies. > > Thanks for all your help. > > > Fr

Ibatis CLOB Support

2009-03-27 Thread a.rubalcaba
I am currently working on a project using Spring + Ibatis. DBA's have recently switched a varchar field into a CLOB field to support large Strings of data. My SQL map has the following which maps to a String object in my java class. I can retrieve data ok. Its when I try to insert data t

Ibatis + Spring

2009-03-27 Thread a.rubalcaba
-- View this message in context: http://www.nabble.com/Ibatis-%2B-Spring-tp22745182p22745182.html Sent from the iBATIS - User - Java mailing list archive at Nabble.com.

Re: How to define alias in

2009-03-27 Thread Jasmin Mehta
alias in SQL will work, Sorry I overlooked the SQL change earlier in first posting. And just saw the table column name in resultMap. I apologies. Thanks for all your help. From: Brandon Goodin To: user-java@ibatis.apache.org Date: 03/27/2009 12:29 PM Subject: Re: How to define alias in You

Re: How to define alias in

2009-03-27 Thread Larry Meadors
You can also poke yourself in the eye with a sharp stick, but in either case it's a bad idea, imo. :-P Larry On Fri, Mar 27, 2009 at 10:10 AM, Brandon Goodin wrote: > You can specify the columnIndex (yuck). >          columnIndex="..."/> >          property="customerDependentVo.depLastName" col

Re: How to define alias in

2009-03-27 Thread Brandon Goodin
You know rethinking your statement. It makes no sense. You just showed us the SQL. You can add an alias in the SQL. It does *not* change your table. It only changes the column name in the result. Then you just map it in the resultMap like we originally said. Brandon On Fri, Mar 27, 2009 at 11:10

Re: How to define alias in

2009-03-27 Thread Brandon Goodin
You can specify the columnIndex (yuck). Brandon Goodin Silver Mind Software http://www.silvermindsoftware.com bgoo...@silvermindsoftware.com 615-306-3652 http://www.linkedin.com/in/bgoodin On Fri, Mar 27, 2009 at 11:03 AM, Jasmin Mehta wrote: > > I can not change the column n

Re: How to define alias in

2009-03-27 Thread Larry Meadors
You just have to change the result map. Larry On Fri, Mar 27, 2009 at 10:03 AM, Jasmin Mehta wrote: > > I can not change the column names of table QOL_DEPENDENT > > from FIRST_NAME to DEP_FIRST_NAME > > It has to be the same. > > > From: Brandon Goodin > To: > user-java@ibatis.apache.org > Dat

Re: How to define alias in

2009-03-27 Thread Jasmin Mehta
I can not change the column names of table QOL_DEPENDENT from FIRST_NAME to DEP_FIRST_NAME It has to be the same. From: Brandon Goodin To: user-java@ibatis.apache.org Date: 03/27/2009 11:59 AM Subject: Re: How to define alias in

AW: How to define alias in

2009-03-27 Thread Benjamin Klatt
Hi Jasmin, you should be able to set different column names in your resultmap like And then use appropriate aliases in your sql query: SELECT cs.cust_status, cu.first_name,

Re: How to define alias in

2009-03-27 Thread Brandon Goodin
SELECT cs.cust_status, cu.first_name, cu.middle_name, cu.last_name, dep.first_name as dep_first_name, dep.last_name as dep_last_name FROM qol_customer cu, qol_dependent dep

How to define alias in

2009-03-27 Thread Jasmin Mehta
Hi, With below code how do I get correct value for dependent first name and dependent last name? Right now as both qol_customer and qol_dependet has same field name for FIRST_NAME and LAST_NAME, I am getting qol_customer's FIRST_NAME and LAST_NAME populated in customerDependentVo.depFirstName

Re: Problem with prepend

2009-03-27 Thread Brandon Goodin
Try adding a prepend to workspace_id. ... The reason this occurs is that the dynamic tag has an automatic removeFirstPrepend="true". Since the isNotNull:position tag is the first to produce a prepend it removes the prepend from the isNotNull:position. Brandon On Fri, Mar 27, 2009 at 3:55 AM,

Re: ibatis - Sybase String problem

2009-03-27 Thread ilkayaktas
Thx my friend, it worked. Brian Bruns wrote: > > You need to explicitly give it the type, so if AD was an int: > > INSERT INTO > HEDEF_TANIMLARI (OID, VERSION, AD) > VALUES (#oid#, #version#, #ad:INT#) > > I've not seen Sybase require this, but DB2 needs the ty

Problem with prepend

2009-03-27 Thread Winarto
Hi All, I'm having problem with the following select statement. SELECT * FROM contexts workspace_id = #workspace_Id# context_id = #context_Id# position