Re: interval operations

Michal Hajek <[email protected]>
Newsgroups gmane.comp.lang.4gl.aubit.general
Message-ID <CAJ7z5acTLGjacnJ3u-Wyas5TjZ0pUxFu0bn6a2qicrhE_17HXw@mail.gmail.com>
That's really quick reaction, Mike :-) Respect.
But I am not familiar with CVS, any link to complete (current) source tarball ?

Thanks, Michal



On Wed, Dec 12, 2012 at 2:08 PM, Mike Aubury <[email protected]> wrote:
> Should be fixed in CVS...
>
> I think the problem is that the result of the subtraction is 0 - and it was
> thinking - thats got no year , or month - so it must be a day to second
> ie. 0 00:00:00.0
>
> You're then comparing that interval with a year to month interval - and its
> saying - no...
> I've coded it so that if it sees a datetime with a precision <= year to
> month - the result of the subtraction must be a year to month.
>
>
> On 12 December 2012 12:30, Michal Hajek <[email protected]> wrote:
>>
>> define XD,DAT date,
>>       I1,I2 datetime year to month
>>
>>  main
>>   let XD="12122012"
>>   let I1=extend(XD, year to month)
>>   let I2=extend(XD, year to month)
>>   if  (I1 - I2 = "0000-00") then
>>        display "OK"
>>   end if
>>
>> end main
>
>

------------------------------------------------------------------------------
LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial
Remotely access PCs and mobile devices and provide instant support
Improve your efficiency, and focus on delivering more value-add services
Discover what IT Professionals Know. Rescue delivers
http://p.sf.net/sfu/logmein_12329d2d
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.