Button for 1977 Button for 1984 Button for 1990 Button for 1995 Button for MDC Button for notes Button for examples

$HOROLOG

M[UMPS] by Example

Introduced in the 1977 ANSI M[UMPS] language standard.

The value of this variable is a code for the current date and time.

$Horolog="51281,44745" on Wednesday, May 27th, 1981 at 25 minutes and 45 seconds past 12 (noon).
$Horolog="53690,86401" on the last second of 1987 (but it is extremely unlikely that anybody actually implemented the concept of "leap-seconds").
$Horolog="1,1" on the second second of Friday, January 1st, 1841.
$Horolog="0,43200" at noon on Thursday, December 31st, 1840.
$Horolog="–30,44745" on Tuesday, December 1st, 1841 at 25 minutes and 45 seconds past 12 (noon).

Note that the sequence at the transition between two days is:
"n,86398" = 23:59:58 or 11:59:58 PM
"n,86399" = 23:59:59 or 11:59:58 PM
"n+1,0" = midnight, or 24:00:00 or 00:00:00 or 12:00:00 AM
"n+1,1" = 00:00:01 or 00:00:01 AM

Interesting values:

$Horolog Date and time
"50000,50000" 24 November 1977, 13:53:20
"51000,51000" 19 August 1980, 14:10:00
"52000,52000" 16 May 1983, 14:26:40
"53000,53000" 9 February 1986, 14:43:20
"54000,54000" 5 November 1988, 15:00:00
"55000,55000" 2 August 1991, 15:16:40
"56000,56000" 28 April 1994, 15:33:20
"57000,57000" 22 January 1997, 15:50:00
"58000,58000" 19 October 1999, 16:06:40
"59000,59000" 15 July 2002, 16:23:20
"60000,60000" 10 April 2005, 16:40:00
"54610,45296" 12:34:56, 7/8/90 (USA: 8 July 1990)
"54640,45296" 12:34:56, 7/8/90 (rest of the world: 7 August 1990)

Be careful with pattern matches: typically, the value of $Horolog will match 5N1P5N, but a really safe check should be 0.1"-"1.N1","1.5N.

The time within the UnixTM operating system is represented as a number of seconds since the start of 1970.
The following extrinsic functions could be used to convert between $Horolog and Unix-time:

Unix(Horolog) Quit Horolog-47117*86400+$p(Horolog,",",2)
Horolog(Unix) Quit (Unix\86400+47117)_","_(Unix#86400)

If the birthdate of M[UMPS] would have been on 23 March 1966 (and in reality it can’t have been more than a year away from that date), then the 50th birthday of the language would be on $Horolog=64000.

Button for 1977 Button for 1984 Button for 1990 Button for 1995 Button for MDC Button for notes Button for examples

Copyright © Standard Documents; 1977-2024 MUMPS Development Committee;
Copyright © Examples: 1995-2024 Ed de Moel;
Copyright © Annotations: 2003-2008 Jacquard Systems Research
Copyright © Annotations: 2008-2024 Ed de Moel.

The information in this page is NOT authoritative and subject to be modified at any moment.
Please consult the appropriate (draft) language standard for an authoritative definition.

Some specifications are "approved for inclusion in a future standard". Note that the MUMPS Development Committee cannot guarantee that such future standards will indeed be published.

This page most recently updated on 15-Nov-2023, 12:07:31.

For comments, contact Ed de Moel (demoel@jacquardsystems.com)