[2263] XML dump of DOUBLE rounds values
Ruslan Zasukhin
sunshine at public.kherson.ua
Tue Mar 27 07:32:06 CDT 2007
On 27/3/07 2:30 PM, "Ruslan Zasukhin" <sunshine at public.kherson.ua> wrote:
> On 27/3/07 11:04 AM, "Stan Busk" <maxprog at mac.com> wrote:
>
>> Hi,
>>
>> Ok and how do you use the SQL SUM statement them? I need to sum
>> dozens of thousands records that way. This is the reason why I use
>> doubles to store doubles and not strings. Now, if SUM also works with
>> strings containing doubles... does it?
>>
>>> This is why I again want to point. If you need EXACT storage of
>>> numbers, DO NOT use DOUBLE/FLOAT type.
>
> More info guys.
>
> 1) I have check how this do mySQL.
>
> they have in CREATE TABLE additional parameters
>
> fld DOUBLE (length, precision)
>
> On default precision = 6.
>
> so as only you give to mySQL value as 23.123456789
> it will be shown as
>
> 23.123457
>
> 2) We have discuss and our vision is:
>
> a) yes we need also add additional parameter(s) to float/double
> to control string conversion.
>
> b) this solve DUMP problem because if you declare field to have
> .3 precision then it is okay to get 3454.127 in the dump.
> c) we need yet add into Valentina new type DECIMAL,
> which internally use 2 integer types to store EXACT values.
> This type also is required to be able do SUM()
AND
I think we can easy enough implement this (length, precision)
parameters for 3.0. In fact SQL parser already understand them I believe.
--
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