Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Number of decimal places
Message
 
 
To
03/10/2010 03:22:39
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
Miscellaneous
Thread ID:
01483618
Message ID:
01483706
Views:
47
>>I'm sure there is an obvious answer but it's the weekend ...
>>
>>Given a numeric variable which may or may not have digits after the decimal point, what would be the quickest way to know the number of digits that occur after decimal point, zero or more?
>
>quickest
>
>
>=MAX(LEN(CAST(m.Number % 1 AS M))-2,0)
>
>* significant decimals only
>
>=MAX(LEN(RTRIM(CAST(m.Number % 1 AS M),"0"))-2,0)
>
>
How do you do the same with float type in SQL Server?
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform