Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Compare field value with zero
Message
From
27/11/2011 10:31:27
 
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01529879
Message ID:
01529880
Views:
44
>Hi,
>
>How do I check if a value in the field is 0 (zero) if the decimal of the field could be any number (e.g. 1,2,4). For example, if field MyField type is Numeric(12,4), and the value in the field is zero, will the following return .T.?
>
>
>? evaluate( cTableAlias + ".MyField" ) = 0
>
>
>That is, do I need to have the decimal 0s specified on the right side of the equation above?
>
>TIA.

No, and you can also use
  ?empty(eval(forceext(m.cTableAlias, 'MyField')))
Gregory
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform