mysql decimal(10,2) extract java -


i have database decimal(10,2) value.

i need extract database , add quantity java, don't it.

from database query, value 5.50

system.out.println(rsmax.getlong(1)); long cost = rsmax.getlong(1) + 2; 

this prints 5 , cost = 7, should print 5.50 , cost = 7.50

how should it?

long integer. need bigdecimal type.


Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -