Use
the method in the ResultSet interface and then cast the object to the
appropriate datatype
Object |
getObject(String columnName)
|
Thanks,
Paul Idusogie
Technical
Architect
Consulting Services
Stellent Inc.
7777 Golden Triangle
Drive
Eden Prairie, MN 55104
Desk: 952.656.2755
Fax:
952.903.2115
Email: [EMAIL PROTECTED]
website: http://www.stellent.com
-----Original Message-----
From: Cutty [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, January 30, 2002 3:03 AM
To: [EMAIL PROTECTED]
Subject: ??: A JDBC problem!I found that when I used DTS of SQL to import data from the Excel files of that format, same problem happened in the same place, maybe this has nothing to do with JDBC ,but I'm still wondering why?
-----Original Message-----
Hi:I have a problem with JSP programming on JDBC ,it is a little bit complex ,but I'll try to make myself clear.I have a table in my database named hcds ,its structure is as follow:..........
Family ModelNo PartNumber SerialNo Customer DateofShipment DateofPurchase HB13L KDD2200 B33400TW 1096706 STD 2001-9-19 2001-10-18 HB13L KDD2200 B33400TW 1096796 STD 2001-9-19 2001-10-18 HB13L KDD2200 B131 NH11T195F8HW NKO 2001-10-11 2001-10-21 HB13L KDD2200 B131 NH10T1A15FV0 NKO 2001-10-26 2001-10-26 ........ ...There are 500 lines in the table.I use getString() to obtain the data from it.The problem is , the getString("SerialNo") returns null on the line where the SerialNo change from a pure numeral format(1096796) to a mixed format (NH11T195F8HW).but it works well if the SerialNo is in a single format.When I picked up four line as showed above to test ,same thing happened. but if I delete first line(whose SerialNo was 1096706) or add some English characters in its SeroalNo colum , the problem did NOT happen;I am so confused and can not solve it.I really appreciate if anybody can help me out of that.Cutty