logo


69.5.0 Date and Time Functions


Here are the date and time functions that are supported by STATIC.

Suppose, for example, the current date is August 15th, 1999, and the current time is 9:00am. Here are the time and date functions:

:

Date and Time Functions

Function

Effect

Example

Current Date

Returns the computer system date.

15/8/1999

Day of

Returns the day number of a date (day-of-the-month).

Day of (Current Date) returns the number 15.

Month of

Returns the month number of a date (month-of-the-year).

Month of (Current Date) returns the number 8.

Year of

Returns the year number of a date.

Year of (Current Date) returns the number 1999.

Date

Converts a string into a date.

The Exclamation Point (!) is used within STATIC to indicate a date in string format.

Date(!15/9/1999!) returns 15/9/1999 (Sept. 15, 1999).

Day Number

Returns the character that the ASCII code represents.

Day Number (Current Date) returns 1 because 15/9/1999 is a Sunday.

Current Time

Returns the computer system time.

The Question mark (?) is used within STATIC to indicate a time in string format.

?9:01:30?

Time string

The Time String function takes the time value as expressed in seconds since midnight and returns the string in HH:MM:SS format.

Time String(43200) returns 12:00:00.



Harrowex Pty Ltd
http://www.hxmedical.com
Voice:+ 61 4 27 344 279
Fax: +61 3 52 439 019
static@hxmedical.com