DAY Variable - Get System Date

Syntax

DAY

Description

The DAY variable returns the 8-byte string last used in a SETDAY statement or the current system date, if no SETDAY verb was used.

NOTE: If the SETDAY verb is used at any time to change the date, the DAY variable will no longer report the current date but will instead report the value last set with the SETDAY verb. Otherwise, DAY returns the current date.

Remarks

By default, DAY variable returns the current date from the server.

In BBj 12.0 and higher, this can be changed to return the date from the client by setting SETOPTS byte 8, bit $08$.

Examples

>SETDAY "03/11/12"
>PRINT DAY
03/11/12
>LET DATE$=DAY; PRINT DATE$(1,2)
03

See Also

Variables - Alphabetical Listing