Yes we had the same issue with the sybase jdbc driver. It was how Village
is implemented providing support for java 1.1, we just patched the village
source locally and used that.
-----Original Message-----
From: Timothy Spear
To: Turbine Users List
Sent: 12/5/01 2:54 PM
Subject: RE: BigDecimal problem
FYI:
I have not looked at the guts of the code. However, Java has
serious
rounding problems with decimal numbers. The only class that seemed to
treat
the decimal values correctly when transforming data types was the
BigDecimal
class. This meant that when retrieving the data from the database in
jdbc, I
had to use the getBigDecimal method on the result set; the getFloat or
getDouble would leave me with rounding issue. Also, you should verify
the
information in the database (I sometimes would blame the retrieval of
the
data, when it was put in incorrectly -- again because of the rounding
problem).
Tim
-----Original Message-----
From: Maciej Leks [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, December 05, 2001 3:17 PM
To: [EMAIL PROTECTED]
Subject: BigDeciaml problem
Hi
In my database scheme I use DECIMAL field type, i.e.
...
<column name="price" required="true" size="8,2" type="DECIMAL">
...
It is wrapped as a BigDeciaml object by the Peer.And here is a problem
because when I put this object into the Velocity context a value
(String) represted by this object is wrongly formated, i.e
Let's consider situation:
In the databese we have: 123.23
But in the Velocity context: 123.2309278382728378237476
Up to now I have to transform the object by hand before I put this
into the context, but it's not good solution!!!
My question is:
Has anyone walk round this problem?
Thanx
--
Leksiu ([EMAIL PROTECTED])
--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>