So the getObject() method of ResultSet is probably returning a Float or a Double (you could easily
test this in you code if you want to find out). And you are adding this value to a StringBuffer which you then output to the console, without imposing any formatting (i.e. just using the default formatting provided by the JRE).
So, update my test class to do this:
And see what format the number takes. Then re-read Paul Clapham's post (paying particular attention to the line "
...numbers don't have any inherent format in Java") and read the JavaDocs for the NumberFormat class.