3 ms·
"One month from now" is horrible. Is that "30 days from now" or "same day number next month"? If the latter, then how do you handle a 31st when the next month
by cryptonector 8y ago
"One month from now" is horrible. Is that "30 days from now" or "same day number next month"? If the latter, then how do you handle a 31st when the next month has 30 days or fewer? (Or a 29th when the next month is February and this is not a leap year?)
This is a difficult subject.
Recurrence is especially tough to model in a database.
- narag 8y agoIt depends on the context. I've programmed date logic for holiday calculation, days open for business and deadlines. I like working with dates because it's always well specified.
- wafflebear 8y agoHow about adding the number of days in the current month?
- cryptonector 8y agoIt depends on user intent. Often the user means "same day of the week, four or five weeks from now".