Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to Convert a char expression into a time expression
Message
 
À
29/09/2006 12:19:00
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Divers
Thread ID:
01158168
Message ID:
01158191
Vues:
21
>I have this two variables:
>
>ltEnterDatetimeEmployee = 29/09/2006 08:45:00 (data extracted from a datetime field)
>
>lcOfficalHourToEnter= "08:30:00" (data extracted from a char field)
>
>I need to determine if an employee is late, comparing both expression..
>
>
>Carlos Burgos
ldtOfficalHourToEnter = DATETIME(YEAR(ltEnterDatetimeEmployee),;
                                 MONTH(ltEnterDatetimeEmployee),;
                                 DAY(ltEnterDatetimeEmployee),;
                                 VAL(LEFT(lcOfficalHourToEnter,2)),;
                                 VAL(SUBSTR(lcOfficalHourToEnter,4,2)),;
                                 VAL(RIGHT(lcOfficalHourToEnter,2)))
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
Répondre
Fil
Voir

Click here to load this message in the networking platform