Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Removing leading zeros
Message
 
To
11/08/1999 13:50:07
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00252593
Message ID:
00252709
Views:
9
>I usually always use ALLTRIM for any string manipulation, just in case. Is their a speed difference? Or any other reason to use LTRIM? Just wondering.
>
>Thanks in advance.

Logic tells me that ALLTRIM does two internal calls to the same functions that LTRIM and RTRIM use. This makes each ALLTRIM twice as long as an LTRIM. Therefore, when using numerics, LTRIM is twice as fast! Same with ATC() when you know both elements are the same case (or searching for non-alpha characters) - use AT() instead.

When you work with large scale systems such as my current contract, every single instruction needs to be evaluated for speed. It's also one of the habits I forced myself to use some years ago (along with specifying SHARED or EXCL when opening tables, among others).
Nigel B Coates
NBC Software Services
Dublin, Ireland.
eMail: Nigel.Coates@NBCSoftware.com
Previous
Reply
Map
View

Click here to load this message in the networking platform