XML Dump random problem with VDouble

Ruslan Zasukhin sunshine at public.kherson.ua
Thu Mar 22 02:02:29 CDT 2007


On 21/3/07 10:20 PM, "Stan Busk" <maxprog at mac.com> wrote:

Hi Stan,

> I have a problem with XML Dump. I never exactly get back what I dump.
> As an example my DB as a record, #1341, where a VDouble is storing
> the value '10149.25'. The XML dump always creates that record with a
> value of '10149.20'. It doesn't happen on all records, only 1% or 2%
> records. Also I can't see any reason or pattern. The number has
> nothing particular, other similar numbers are dumped correctly.
> 
> This is how the record looks like in the app:
> http://www.maxprog.com/misc/valentina/record.jpg
> The on-list data and edition data are made thru 2 different queries.
> All the app (reports, stats, etc...) show that record with '10149.25'.

You use DOUBLE value to keep money value?

This is not a good idea. DOUBLE is not infinite sequence in the computer
CPU.

Better use STRING 
or I have hear people use 2 INT fields:

        194.25  =>  194 and 25

 
> This is an extract of the XML dump for that record:
> 
> <Record>
>     <f n="RecID">1341</f>
>     <f n="Transaction_Date">10/25/2004</f>
>     <f n="Transaction_Type">7</f>
>     <f n="Transaction_AccountDebited">17</f>
>     <f n="Transaction_AccountCredited">1</f>
>     <f n="Transaction_Amount">10149.2</f>
>     <f n="Transaction_Comment"><![CDATA[]]></f>
>     <f n="Transaction_InvoiceNum"><![CDATA[]]></f>
> </Record>
> 
> The amount is converted to '10149.2'. I found a dozen of such errors
> out of 2500 records.
> 
> I would say it is a bug. I can create a report at mantis. What do you
> need?

I think first of all this can be checked in Valentina Studio with one table
and one field and one this value 10149.25.  If this reproduce then enough.


-- 
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina - Joining Worlds of Information
http://www.paradigmasoft.com

[I feel the need: the need for speed]




More information about the Valentina mailing list