Day of Week Function

Oran Shapitka shapitka@cips.ca
Fri, 24 Jul 1998 08:33:37 -0600


Divide the days since 19000101 by 7.  The remainder will tell you the day of
the week.

define d-start-day      integer   * 01 =                            &
  mod(days(19980723),7)

;                                  when remainder = 0 then sunday
;                                                   1 then monday
;                                                   2 then tuesday
;                                                   3 then wednesday
;                                                   4 then thursday
;                                                   5 then friday
;                                                   6 then saturday

Oran Shapitka, ISP
Intertech Business Systems, Inc.
1564, 10303 Jasper Ave
Edmonton, AB  T5J 3N6  Canada

Email:	shapitka@cips.ca
Voice:	(403) 413-0400
Fax:	(403) 413-0398

-----Original Message-----
From: owner-powerh-l@sphere.swau.edu
[mailto:owner-powerh-l@sphere.swau.edu]On Behalf Of Robert Elsner
Sent: July 24, 1998 7:16 AM
To: POWERH-L@lists.swau.edu
Subject: Day of Week Function


Hi,

   I was wondering if any of you know of a way of getting the day of the
week from any date.


For instance, if I give the computer 19980723 I would like it to tell me
that the day is Wednesday. And give me the day for any date that I
specify.

Thanks in advance

--
Robert Elsner
Financial Aid -- Powerhouse Programmer
Southwestern Adventist University
Junior Computer Science Student

= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
Subscribe: "subscribe powerh-l" in message body to majordomo@lists.swau.edu
Unsubscribe: "unsubscribe powerh-l" in message to majordomo@lists.swau.edu
powerh-l@lists.swau.edu is gatewayed one-way to bit.listserv.powerh-l
This list is closed, thus to post to the list, you must be a subscriber.

= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
Subscribe: "subscribe powerh-l" in message body to majordomo@lists.swau.edu
Unsubscribe: "unsubscribe powerh-l" in message to majordomo@lists.swau.edu
powerh-l@lists.swau.edu is gatewayed one-way to bit.listserv.powerh-l
This list is closed, thus to post to the list, you must be a subscriber.