Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Select to integer
Message
From
09/10/2001 11:26:53
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00565961
Message ID:
00565982
Views:
15
>What do you need to convert and how? For example you can use round(..,0), int() or ceil() for numeric fields having decimals. If you need to set field size, say to 10, then you can use something like 0000000000+round(..,0) (though it may fail for size of round(..) > 10).
>
>>When SELECTing into a cursor, is there a way to convert to Integer? Int(MyNumericField) seems to create a field of type N(10).
>>
>>Hilmar.

Well, it is actually someone I know who wanted to do this. The expression involved an iif(). I already suggested using N(10) instead - which is what I would do for myself. I was just wondering whether there was a direct way to select, something like NumericToInt(MyNumericField). It seems there isn't.

Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Reply
Map
View

Click here to load this message in the networking platform