db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel John Debrunner <...@debrunners.com>
Subject Re: Inconsistencies in PreparedStatement.setFloat/setDouble
Date Thu, 09 Sep 2004 22:29:31 GMT
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Nate McKie wrote:

> We have found in using Cloudscape/Derby that there are inconsistencies in
> the behavior of how floating-point numbers are saved to the database
> depending on whether you use PreparedStatement.setFloat or
> PreparedStatement.setDouble.  setDouble seems to work better.
>
> These problems are predictable and repeatable, and we've written some
Junit
> tests to show what happens.  Here's a link to the base code for what we
> wrote:
>
> 	http://demo0.asolutions.com/CloudscapeInsertionAnomalyTest.java
>
> You can't run this code without the database schema and some helper
classes,
> but I can assure you that all of these tests pass.

Since the code cannot be run, can you give a summary of what values you
sent to the database and what was retrieved. For both float and double
methods. Preferably printing the value of 'preInsert' and 'postInsert'.

Dan.

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFBQNlLIv0S4qsbfuQRAi8PAKCDaF6j3eV0j7QhSzvkHpydfp+CzwCgqmuu
LzlbfmbkRfNw8M5hhKtPZwQ=
=4Sog
-----END PGP SIGNATURE-----


Mime
View raw message