Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

convert 3E+1 into 30  RSS feed

 
Ranch Hand
Posts: 598
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In my database I have a int which isset to 30, using IBATIS to extract this int it turns it into a string notation 3E+1 it is then set as a BiGDecimal on a setter as 3E+1, looking at the best way to convert it back to 30
 
Sheriff
Posts: 21135
87
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
BigDecimal's toPlainString() method should do the trick.
 
Tony Evans
Ranch Hand
Posts: 598
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks that worked.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!