Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Simple math problem
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01122177
Message ID:
01122201
Vues:
22
This message has been marked as a message which has helped to the initial question of the thread.
>>>Hi everybody,
>>>
>>>If we have these numbers
>>>123000
>>>130000
>>>140400
>>>
>>>and we need 123, 13, 1404 (e.g. remove the trailing zeros), can we do it without loop? I don't see a way after thinking 3 minutes on the problem.
>>>
>>>Thanks in advance.
>>
>>?CHRTRAN(ALLTRIM(CHRTRAN(TRANSFORM(myNumber),[0],[ ])),[ ],[0])
>>
>
>Sergey's solution seems to be the easiest one, as always <g>

Yes, I always forgot that we have possibilities to put what char we want to remove :o) in xTRIM() functions.
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform