Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Date function
Message
De
26/01/2016 08:51:36
Lutz Scheffler
Lutz Scheffler Software Ingenieurbüro
Dresden, Allemagne
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Divers
Thread ID:
01630218
Message ID:
01630220
Vues:
62
>I have seen some code which is as follows
>
>select names
>set order to tag datex
>set key to dtot({})
>
>The file is ordered by date time
>
>Does the set key set a filter to today's date?
>
>If not what does it do?

You should finaly learn how to use this forum, in special the pre tags. Is it realy that tricky to copy a couple of lines out of a reply?

How to test?
?dtot({})
?dtot({})=DATETIME()
?dtot(DATE())=DATETIME()
?dtot(DATE())
DATETIME is a second, you compare the first second of today with any other second of today. This will not match. Or only by a chance of 1/86400.

The riddle might be solved with
HELP SET KEY
Pro tip:
set key to RANGE dtot(DATE()),dtot(DATE()+1)-1
*IOW SET KEY to a range between the first second of today and a second before the first second of tomorow, aka the last second of today.
Alles klar?

:D
Words are given to man to enable him to conceal his true feelings.
Charles Maurice de Talleyrand-Périgord

Weeks of programming can save you hours of planning.

Off

There is no place like [::1]
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform