Link to home
Start Free TrialLog in
Avatar of xiaoxiangz
xiaoxiangz

asked on

ResultSet getObject question?

Hi, I am using  ResultSet.getObject method to
retrieve Oracle data through JDBC .  If I use
getString , it works.  But when I use getObject
, I got all null.  The data type in Oracle table is number, the responding java data type should be
BigDecimal.

Thanks.
Sean
Avatar of kotan
kotan
Flag of Malaysia image

why don't you use resultset.getBigDecimal().
Avatar of xiaoxiangz
xiaoxiangz

ASKER

Well, in the future, the oracle table may contain
other type of fields, such date and integers.  So I want to use getObject().
ASKER CERTIFIED SOLUTION
Avatar of pothuganti_srinivas
pothuganti_srinivas

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial