Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
GOMONTH(DATE(),-(YEAR(DATE())-1753)*12)
Message
De
21/03/2000 08:09:22
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00347376
Message ID:
00348263
Vues:
24
>I'd say that the current behavior of GOMONTH() in regard to the year of 1753 is not warranted, and not documented (does this qualify it as a bug?),

Well, it may not be documented in Help, but it is in HackFox <g>. That's how I knew. Ted knows all this esoteric stuff about dates.

I don't think it's unreasonable for the function to work only in the range where its results make sense in a large portion of the world. That is, they know that calculating by months fails at some point because of the adjustments to the calendar when countries switched to Gregorian. Different countries changed at different times. They could have picked any of those dates as the cut-off for GOMONTH(). Not choosing one of them would have been irresponsible, I think. 1752 was a good one because the British Empire was a fair chunk of the world and, more importantly, takes in a significant portion of the places where VFP is used. The other reasonable choice would have been 15xx (I forget exactly) when the Gregorian calendar was first introduced.

However, it should be documented in Help. Garrett, you putting that through as a doc bug?

Tamar
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform