Table 5.4. Commonly Used Elements of the DATE Format Mask
Format
Description
YYYY
Four-digit year.
YEAR
Year, spelled out.
RR
Two-digit year, based on century. If two-digit year is between 50 and 99, then it’s the previous century; if the year is between 00 and 49, it’s the current century.
MM
Two-digit month.
MON
Three-letter abbreviation of the month, in uppercase letters.
MONTH
Month, spelled out, in uppercase letters and padded with blanks.
Month
Month, spelled with, first letter uppercase and padded with blanks to a length of nine characters.
DD
Numeric day (1–31).
DAY
Day of the week, spelled out, in uppercase letters and padded with blanks to a length of nine characters.
DY
Three-letter abbreviation of the day of the week, in uppercase letters.
D
Day of the week number (1–7), where Sunday is day 1, Monday is day 2, and so forth.
DDD
Day of the year (1–366).
DL
Day long format; the equivalent format mask is fmDay, Month DD, YYYY.
HH or HH12
Hours (0–12).
HH24
Hours in military format (0–23).
MI
Minutes (0–59).
SS
Seconds (0–59).
SSSSS
Seconds past midnight (0–86399).
AM or PM
Meridian indicator.
TS
Short time format; the equivalent format mask is HH:MI:SS AM.