Below is a full list of the format models that are available to be used with the ROUND(date)
and TRUNC(date)
functions in Oracle Database.
Format Model | Rounding or Truncating Unit |
---|---|
CC SCC | One greater than the first two digits of a four-digit year. |
SYYYY YYYY YEAR SYEAR YYY YY Y | Year (rounds up on July 1). |
IYYY IYY IY I | Year containing the calendar week, as defined by the ISO 8601 standard. |
Q | Quarter (rounds up on the sixteenth day of the second month of the quarter). |
MONTH MON MM RM | Month (rounds up on the sixteenth day). |
WW | Same day of the week as the first day of the year. |
IW | Same day of the week as the first day of the calendar week as defined by the ISO 8601 standard, which is Monday. |
W | Same day of the week as the first day of the month. |
DDD DD J | Day |
DAY DY D | Starting day of the week. The starting day of the week is specified implicitly by the NLS_TERRITORY initialisation parameter. |
HH HH12 HH24 | Hour. |
MI | Minute. |