1267Re: [ISO8601] Re: Just read Oracle has NEXT_DAY and LAST_DAY functions
- Mar 1, 2005In a message dated 3/1/2005 8:03:44 A.M. Central Standard Time, johnmsteele@... writes:Are you asking how the calculation is done? Generally the year and month are converted to a Julian day count modulo 7 to remove whole weeks. This aligns the days of the month with the days of the week and little math answers any of those questions. As I said before, no problem if the application has a form to determine such things, but transmitting it as a date notation and leaving the receiver to figure it out is not useful, IMO.
hjwoudenberg@... wrote:I want to know to know how to annotate it.I get the last day of the month by:1. setting the current day to the first day of the month2. Adding one month (must handle month 12 separately)3. Convert the date to days4. Subtracting on day.5. Convert date to Gregorian calendar date.I think we should have a notation so that a function can do this like regular time intervals.hjw
- << Previous post in topic Next post in topic >>