Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Why won't return a value with Decimal Places ??
Message
From
24/01/2003 20:48:49
Gerry Schmitz
GHS Automation Inc.
Calgary, Alberta, Canada
 
 
To
24/01/2003 20:15:57
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00744962
Message ID:
00745341
Views:
24
>How you find the answer for this ?? Microsoft knowledge base has provide
>answer ??

Did not check the MS KB ... I knew that "constants" can influence output field sizes in SQL SELECTs so you should (always) do a LIST STRUCTURE to verify the results. Then it's a matter of playing with the SELECT until you get the effect you want.

>
>--This is one example of how VFP can corrupt numeric table data....
>
>Any others example ?? ^_^

Try this:
CLEAR
CREATE CURSOR TABLE1 (FLD1 C(1), FLD2 C(2), FLD3 N(3,2))

ON ERROR *

SELECT TABLE1
APPEND BLANK

REPLACE FLD3 WITH 34 * 1234.56
?  "(1) "
?? FLD3
?  "(2) "
?? TYPE( "FLD3" )
?  "(3) "
?? FLD3 * 1.0
?  "(4) "
?? FLD3 > 5000000000000

WAIT WINDOW "..."

BROWSE
Scary, huh ?
Previous
Reply
Map
View

Click here to load this message in the networking platform