Information générale
Catégorie:
Codage, syntaxe et commandes
Do you really want YYYYDDD where DDD is actually the day of the year? i.e. 001 -> 365 (or 366) Is 2003001 = to January 1st, 2003?
I know that many non-computer / non-mathematicians refer to this as a Julian date, even through it's not really.
If 2003001 is a numeric (say lnJulian), then to get a VFP date, try:
?date(int(lnJulian/1000), 1, 1) + mod(lnJulian, 1000) - 1
If 2003001 is a character string (say lcJulian), then to get a VFP date, try:
?date(val(left(lcJulian, 4)), 1, 1) + val(right(lcJulian, 3)) - 1
Rick
>Hi,
>
>I have a julian date that I need to convert into VFP date format.
> Does anyone know the command to do it? I checked Sys(10) & Sys(11). They don't seem to help..
>julian date looks like this. 2003001
>
>TIA
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement