Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
TimeStamps calculating differently
Message
De
16/08/2007 12:48:17
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
01248245
Message ID:
01248566
Vues:
26
>>Never search like this:
>>
>>
select * from myTable where myDatetime = m.ltDatetime
>>
>>But like this:
>>
>>
select * from myTable where ttoc(myDatetime,1) == ttoc(m.ltDatetime,1)
>>
>>or a similar expression.
>>Cetin
>
>When > < Between() is it also better to use ttoc()? Like ttoc(myDatetime,1) >= ttoc(m.ltDatetime,1)

I'd say so, because your variable is again prone to this roundoff error, and if its value is one of those that don't calculate correctly, it may not match the one record which has the same datetime (but not exactly the same). Though the chances for this error are low, once it happens you may lose a lot of time trying to figure it out.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform