Author
BigDecimal question
Red Green
Greenhorn
Joined: Sep 27, 2001
Posts: 15
posted Oct 09, 2001 11:27:00
0
java.math.BigDecimal gotNum = rs.getBigDecimal("someNumericValue");
Paul Stevens
Ranch Hand
Joined: May 17, 2001
Posts: 2823
D
Red Green
Greenhorn
Joined: Sep 27, 2001
Posts: 15
posted Oct 09, 2001 11:40:00
0
i am sorry about the initial posting, i guess i didn't do a full copy before my cut and paste. anyway the question is: is this the correct format to get the numeric value from the recordset? java.math.BigDecimal gotNum = rs.getBigDecimal("someNumbericValue");
saravanan balu
Ranch Hand
Joined: May 19, 2000
Posts: 49
Hi, when you say the column value is numeric you can use rs.getInt("columnName") also, it depends upon the column's datatype.
Dirk Schreckmann
Sheriff
Joined: Dec 10, 2001
Posts: 7023
saravanan balu, You might notice that the date of the initial post is from almost three years ago. ---- Red Green, Should you ever return... Welcome back to JavaRanch! We ain't got many rules 'round these parts, but we do got one. Please change your display name to comply with The JavaRanch Naming Policy . Thanks Pardner! Hope to see you 'round the Ranch! ---- Moving this to the JDBC forum ... [ June 10, 2004: Message edited by: Dirk Schreckmann ]
[How To Ask Good Questions ] [JavaRanch FAQ Wiki ] [JavaRanch Radio ]
subject: BigDecimal question