Fairly simple; The iconv opens up a worm hole sends the date information
through to a super computer in the future which cranks out an answer and
sends it back to the iconv a fraction of a second later.

-----Original Message-----
From: MAJ Programming [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, July 11, 2007 8:08 PM
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] [UV] Conversion code for week number

So we're guessing.

I gotta believe that there's something to it instead of simply counting
days, dividing by 365.25, carrying the 3, square root of October etc.

How does 1/1/68 mean 'divide by 365.25'? Also, divide 'what' by 365.25 ?

Considering how incredibly often the function is used and how blazingly
fast
it does its ICONVs and OCONVs, there must be something more to it.

Thanks
----- Original Message -----
From: "Timothy Snyder" <[EMAIL PROTECTED]>
To: <u2-users@listserver.u2ug.org>
Sent: Wednesday, July 11, 2007 12:06 PM
Subject: RE: [U2] [UV] Conversion code for week number


> > I know you said "don't tell me it's the base date", but the date
1/1/68
> > was chosen for a reason - it means "divide by 365.25" actually gives
the
> > right answer...
>
> Anybody that relies on that in code is bound to get a nasty surprise.
> There are dates for which that doesn't work.  Try it with July 7,
2006.
> Today's date is 14437, a year ago was 14072.  The difference is 365.
> Divide that by 365.25 and you get less than one year.  The argument
could
> be made that you could round it after the division, but that will
throw
> other dates off.  The bottom line is that this is not a safe way to
> accurately calculate an age - it's *almost* always right, but when
that's
> not good enough, it shouldn't be used.
>
> Tim Snyder
> Consulting I/T Specialist
> U2 Lab Services
> Information Management, IBM Software Group
> -------
> u2-users mailing list
> u2-users@listserver.u2ug.org
> To unsubscribe please visit http://listserver.u2ug.org/
-------
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
-------
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/

Reply via email to