Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Bug in currency data type? Someone Explain this one.
Message
 
À
20/07/2000 10:37:47
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00394894
Message ID:
00395040
Vues:
12
Ken,

No Bug here,

>*******************************************
>t = 7.25
>
>p = 65.31
>? ROUND(p * (t/100), 2)

? p * (t/100)
Returns 4.734975 which will round to 4.73


>
>CORRECTLY returns 4.73
>
>
>* now - with p as currency
>p = $65.31
>? ROUND(p * (t/100), 2)

? p * (t/100)
Returns 4.7350 due to fixed decimals in currency which will round to 4.74


>
> CORRECTLYreturns 4.74!!!!
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform