Date (command)

From Br Wiki
Jump to: navigation, search

See also Date (disambiguation)

The Date command sets the session date, which determines the value of the string function DATE$. This has no effect on the underlying system date, and this setting is lost when BR is exited.

Comments and Examples

The following example sets the month to 10 (October), the day to 16, and the year to 1989:

 DATE 10-16-89

The next example will return a string similar to: Monday, October 16, 1989

 Date$("Day, Month D, CCYY")

Syntax

DATE {[mm-dd-yy]|[mm/dd/yy]}

DateCommand.png

Default

Return the date in yy/mm/dd format.

Parameters

Date's two parameter formats allow you to separate the elements of the date by slashes ("mm/dd/yy") or by dashes ("mm-dd-yy").

Technical Considerations

Changes to the date apply only to a single workstation - current session only. Note that date is set as month, day and year, while it is reported by the date command as year, month and day. This is a legacy characteristic that has not been changed because normally the DATE function is used by programs instead of the DATE command.