Re: Bug in FromDate
- To: mathgroup at smc.vnet.net
- Subject: [mg49130] Re: [mg48903] Bug in FromDate
- From: "Sébastien de Menten" <sdementen at hotmail.com>
- Date: Fri, 2 Jul 2004 02:01:35 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
>>>I am using FromDate with arguments outside the usual scope but don't >get any sensible result. > >Why should you? > Because sometimes it may be quite handy to be able to say: the date 20 months after the day d with just ToDate[FromDate[d + {0,20,0,0,0,0}]]. In fact, this is the behaviour of the mktime function of the standard C library (allow any range in the different time fields year, month,etc and normalise them in mktime). >>>I am using FromDate with arguments outside the usual scope but don't >get any sensible result. > >Why should you? > >Bobby > >On Tue, 22 Jun 2004 05:32:21 -0400 (EDT), Sebastien de Menten ><sdementen at hotmail.com> wrote: > >>Hi, >> >>I am using FromDate with arguments outside the usual scope but don't >>get any sensible result. >> >>The first example is OK: >>ToDate[FromDate[{2004,14,1,0,0,0}]] -> {2005,2,1,0,0,0} >> >>While the second is wrong: >>ToDate[FromDate[{2004,15,1,0,0,0}]] -> {2005,3,4,0,0,0} instead of >>{2005,3,1,0,0,0} >> >>Does anybody know the expected behaviour of FromDate ? >> >>TX >>Seb >> >> > > > >-- >DrBob at bigfoot.com >www.eclecticdreams.net/index.html > _________________________________________________________________ MSN Geldzaken adviseert... http://money.msn.be