Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Returning a Time value from a DateTime expression
Message
De
28/11/2003 07:34:34
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
28/11/2003 06:38:14
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00854154
Message ID:
00854171
Vues:
18
>Hi Jos,
>
>Thanks for the tip. Do you think this would work?
>
>set filter to between(ctot(ttoc(datetime,2)),{08:00:00 PM},{11:00:00 PM})

Yes would work. All would resolve to time values on 12/30/1899.
However due to internal math with datetime values you might miss some records which are appaerantly on 8 PM or 11 PM. For this reason I suggest you to make char based comparison. ie:

set filter to between(substr(ttoc(datetime,1),9),'20','23')

Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform