DATETONR

Syntax:

DATETONR(D the_date)

 

Return Value:

N numeric_representation

 
Precedence:12
Description:

DATETONR converts a date to the number of days since 1st March 1980
To work out the day of the week, use MOD 7. The date 1st March 1980 is a Saturday, and so the modulus will range from 0 for Saturday through to 6 for Friday

 

Example:

DATETONR(02.03.81) = 366
DATETONR(08.03.80) MOD 7 = 0 {Saturday gives 0}