Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Round() Bug
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Divers
Thread ID:
00459503
Message ID:
00459578
Vues:
25
>The maximum number of decimals [from TRANSFORM], BTW, is 12, as I just found.

See what you get with the following. It would suggest that the limit is 17 - sixteen significant digits plus the decimal point.
tnnumber=2.0000000056984984924892482948294829
?transform(tnnumber)  && 2.000000005698499
?len( transform( tnNumber))  && 17

tnnumber=2.123456789012345678  && 1 to the left, 18 to the right
?transform(tnnumber)  && 2.123456789012346 - note the rounding
?len( transform( tnNumber))  && 17

tnnumber=22.123456789012345678  && 2 to the left, 18 to the right
?transform(tnnumber)  && 22.12345678901234 - no rounding here - why not??
?len( transform( tnNumber))  && 17

tnnumber=123456789.123456789  && 9 to the left and 9 to the right
?transform(tnnumber)  && 123456789.1234568
?len( transform( tnNumber))  && 17
Rick Borup, MCSD

recursion (rE-kur'-shun) n.
  see recursion.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform