Skip to Main Content

New to Java

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to convert the float value 4.067851822E9 into a normal number

843785Feb 26 2009 — edited Feb 26 2009
Hi peeps,

I am a bit stuck here. Basically I am outputting a sum of int values from a database. However I have realised that I have exceeded the maximum value that can fit into an int and hence the output gives me the value 2147483647 which is the maximum value of int. When I cast the sum of the int values into a "float" and output the float value, I get the value 4.067851822E9.

My question is, how can I convert the float value 4.067851822E9 into a normal number 4067851822. Can someone please guide me in the right direction.

Thanks,
Ket
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 26 2009
Added on Feb 26 2009
5 comments
1,141 views