Article 147923 of comp.os.vms:

In article <4ntebv$j3h@gap.cco.caltech.edu>, carl@SOL1.GPS.CALTECH.EDU (Carl J Lydick) writes...
> 
>VMS is perfectly content with times up to 31-DEC-9999 23:59:59.99.  After that,
>its ASCII representation has problems, though the internal time format
>continues to work for quite some time after that.  Let's see.  
>There are about 365*24*60*60*100=3153600000 centiseconds in a year. 

Correct.

> Time is measured for VMS purposes in centiseconds.  

Incorrect. Measured in 'cluncks' of 100 nanosecond each.

So a year is less than what can be dealt with by an
>unsigned longword.  That leaves us with the first 31 bits of the high-order
>longword in the date/time for years, more or less (the high-order bit is used
>to distinguish between absolute and delta times).  So the 64-bit time format
>runs into problems somewhere around the year 2,000,000,000.

Wrong. Why not try it out before responding? My favourite technique for
that is to use the debugger. Here is a sample log:


$run/deb tmp ! Any program will do
DBG> set rad hex
DBG> dep 200=0
DBG> dep 204=0ffffffff
DBG> ex/date 200
00000200:          0 00:07:09.49

So here we see that the lower 32 bits hold 7 minutes worth of cluncks.

DBG> dep 204=0ffffff00
DBG> ex/date 200
00000200:          1 06:32:31.16    -> next byte is roughly a day (30 hours).
DBG> dep 204=0ffff0000
DBG> ex/date 200
00000200:        325 18:44:57.60    -> next byte about a year (320 days).
DBG> dep 204=0ff000000
DBG> ex/date 200
%DEBUG-E-DELTIMTOO, delta time too large  -> more than 9999 days.

Or using absolute dates

DBG> dep 204=1
DBG> ex/date 200
00000200:       17-NOV-1858 00:07:09.49
DBG> dep 204=01000000
00000200:       20-MAR-2087 23:50:03.79

	So a next 'signifact' event for the 64 bit date is in less than
	100 years from now when the upper byte will start to be used.

DBG> dep/date 200="--9999"
DBG> ex/date 200
00000200:       24-MAY-9999 01:18:51.19
DBG> ex/quad 200
00000200:       23A68F7F 84BACD60

The highest allowed ascii time: year 9999 has value 23x in the 
most significant byte. It can go to 7Fx there or in other words
more than 30,000 years., NOT millions and millions of years.


Actually I suspect the the next significant event in dates and VMScomputers
will NOT be 2000 but rather sooner in less than a year from now.
At that time it will be 9999 days from 1-jan-1970 and calculation
using that 'unix' base date mixed with vms delta time may well fail :-).

Hope this helps,		+--------------------------------------+
Hein van den Heuvel, Digital.	| All opinions expressed are mine, and |
  "Makers of VMS and other	| may not reflect those of my employer |
   fine Operating Systems."	+--------------------------------------+


