On Wed, 19 Sep 2001, Edward G. Orton wrote:

> Yes, it is just arithmetic, but it isn't *just* arithmetic. Maybe the
> example was a poor one, but what, with just arithmetic, is the
> differemce between January 1, 1999 and March 1, 2001. It's a little
> more complicated than you describe.

Agreed. Apologies for wrapping a cheap joke in a cheap answer. There *are*
a lot of subtleties to account for (number of days in a month, leap years,
leap seconds, etc) and doing anything other than a certain fraction of
short range offsets (that is, say, differences of a week or so, preferably
within the same month, etc) goes beyond the level of being trivial. 
 
Also, Jenda's observation that the original question seemed to be about
ODBC was a good one. If this is a database question then there may be ways
of solving this with vendor specific SQL, and depending on what you're
doing it might make sense to take advantage of them. But a good, robust,
portable, vendor-etc-neutral solution will probably involve using one or
both of the previously mentioned Date::Manip & Date::Calc libraries. 

More info on the task involved might help to narrow down just what exactly
would work best, and how it should be applied, etc. 


-- 
Chris Devers                     [EMAIL PROTECTED]

_______________________________________________
Perl-Win32-Web mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/perl-win32-web

Reply via email to