fields with float[48] type question - Mailing list pgsql-sql

From Sergey S. Rakitin
Subject fields with float[48] type question
Date
Msg-id 375E8C0D.1A8B5FDD@visti.net
Whole thread Raw
List pgsql-sql
Hi,
I have two pc's with PostgreSQL 6.4.2r and 6.5beta2and some troubles with both of them.
Well, here's an example:I create some simple table with float field (called field_one), insertvalue 100 in it. Then I
needto increase/decrease it number by 0.06 on
 
every stepmany times (from trigger/SPI or simple shell script contains just _21_
(or less)lines like this: 'update <class_name> set field_one = field_one [-+]
0.06')...Here'we go. If I put _22+_ lines I got very interesting results. For
example:100 - 22 times by 0.06 == 98.6799999999999 instead of 98.68... And it's
notthe end of story...

    Can someone explain me such behaviour?..

--Sergey S. Rakitin        ElVistiSSR2-RIPE          Information Center


pgsql-sql by date:

Previous
From: Tom Lane
Date:
Subject: Re: [SQL] Select like when searching for whole word and optimizing it
Next
From: "Nikolay Mijaylov"
Date:
Subject: Re: [SQL] automatic incrementation