Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
ROUND()
Message
General information
Forum:
Visual FoxPro
Category:
Other
Title:
Miscellaneous
Thread ID:
00342568
Message ID:
00343896
Views:
39
I also get different results depending on my SET FIXED setting too. Do you usually keep SET FIXED on or off?

Anyways, I never rely on this stuff. I always implicitly define how the output is to appear and I always use ROUND() when necessary.

I took a look. I can't find a SET DECIMALS or a SET FIXED in any of my code. No wonder this is all new to me...

Take care,
Joe


>Joseph,
>
>To see what I am saying try this one;
>
>
>SET DECIMAL TO 1
>lnVar1 = 44/7
>? lnVar1 && 6.3
>SET DECIMAL TO 2
>lnVar2 = lnVar1 * 1
>?lnVar2
>disp memo like ln*
>
>
>Pay carefull attention to the two values that display memo shows you, one is formatted to the decimal setting and the other is the actual value in memory.
>
>What we are seeing here is the very reason that I NEVER use SET DECIMALS. When I need a specific decimal precision I use the ROUND() function to make it.
Joseph C. Kempel
Systems Analyst/Programmer
JNC
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform