Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Only currency is sure computation decimals values ?
Message
De
11/06/2003 10:30:06
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
11/06/2003 09:49:10
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00798893
Message ID:
00798924
Vues:
43
>Hi,
>
>I suspected from much time, but me it seemed impossible.
>
>
>CREATE CURSOR TEST (b B DEFAULT 0.1,n N(18,4) DEFAULT 0.1,y Y DEFAULT $0.1)
>FOR I=1 TO 10000000
>	APPEND BLANK
>NEXT
>SELECT ROUND(SUM(b),4) sb,sum(y) sy,sum(n) sn FROM test INTO CURSOR result
>
>? TRANSFORM(sb+0.000000000000000)
>? sn
>? sy
>
>
>Where it is my error?
>
>Fabio

Fabio,
CREATE CURSOR TEST (Amt i,b B(5),n N(18,5),y Y)
for ix=1 to 100
 insert into test values (ix,ix/100000,ix/100000,ix/100000)
EndFor

SELECT sum(amt) amt,sum(b) sb,sum(y) sy,sum(n) sn ;
 FROM test ;
 INTO CURSOR result
 
? amt, sb, sn, sy 
IOW we're just wasting time.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform