I agree - of all the jdbc drivers I have ever used, DB2 is the only
one that supports this.

Larry


On Wed, Feb 27, 2008 at 8:45 AM, Jeff Butler <[EMAIL PROTECTED]> wrote:
> This seems like an obvious error in iBATIS to me.  I made the change and ran
> the build - the tests all passed.
>
> Unless anyone has a strong objection, I'll commit the change.
>
> Thanks to Rikki for doing the diagnosis on this!
>
> Jeff Butler
>
>
>
>
>
> On Wed, Feb 27, 2008 at 7:43 AM, Niels Beekman <[EMAIL PROTECTED]> wrote:
>
> >
> >
> >
> >
> > I think that this affects the aliasing of columns, which would be bad
> IMHO. But the javadoc of getColumnLabel says:
> >
> >
> >
> > "Gets the designated column's suggested title for use in printouts and
> displays."
> >
> >
> >
> > This would mean that it's perfectly valid to call getColumnName, maybe
> someone with more JDBC spec knowledge can comment on this.
> >
> >
> >
> > Niels
> >
> > ________________________________
>
> >
> > From: Rikki Bindra [mailto:[EMAIL PROTECTED]
> > Sent: Wednesday, February 27, 2008 12:04 PM
> > To: [email protected]
> > Subject: Undefined Column Name Exception in Implicit Map
> >
> >
> >
> >
> >
> >
> >
> > Hi,
> >
> > I am using the jt400.jar as the JDBC Driver for accessing data from DB2
> database on AS400. The problem is that I want to use implicit resultmap like
> >
> > <select id="getProductCount" resultClass="java.util.HashMap">
> > select * from PRODUCT
> > </select>
> >
> > However, the problem is that while populating the HashMap, I have noticed
> that the class "com.ibatis.sqlmap.engine.mapping.result.AutoResultMap" uses
> method getColumnLabel() on ResultSetMetaData
> > My JDBC driver returns the label of the column (containing spaces and
> which is different than the column name in database). Now the code fails
> reporting the exception that "Invalid Column Name" has been specified. The
> problem is in the class
> "com.ibatis.sqlmap.engine.mapping.result.AutoResultMap" as it should be
> calling getColumnName() instead of getColumnLabel() on ResultSetMetaData to
> get the names of the columns.
> >
> > Please look this ASAP and confirm if changing the method call from
> getColumnLabel() to getColumnName(), can affect in what manner.. I have
> tried this and it works for me. However, I want to know the unknown
> implications that it might have.
> >
> > Thanks & Regards,
> > Rikki Bindra
> > Tata Consultancy Services
> > C - 56, Phase 2
> > Dist. Gautam Budh Nagar
> > Noida - 201305,Uttar Pradesh
> > India
> > Mailto: [EMAIL PROTECTED]
> > Website: http://www.tcs.com
> > ____________________________________________
> > Experience certainty.        IT Services
> >                        Business Solutions
> >                        Outsourcing
> > ____________________________________________=====-----=====-----=====
> > Notice: The information contained in this e-mail
> > message and/or attachments to it may contain
> > confidential or privileged information. If you are
> > not the intended recipient, any dissemination, use,
> > review, distribution, printing or copying of the
> > information contained in this e-mail message
> > and/or attachments to it are strictly prohibited. If
> > you have received this communication in error,
> > please notify us by reply e-mail or telephone and
> > immediately and permanently delete the message
> > and any attachments. Thank you
> >
> >
> >
>
>

Reply via email to