Warning: This Help page is relevant to LibreOffice up to version 6.0.
For updated Help pages, visit https://help.libreoffice.org.

WEEKNUM

From LibreOffice Help
Jump to navigation Jump to search

WEEKNUM

WEEKNUM calculates the week number of the year for the internal date value.

Note.png The International Standard ISO 8601 has decreed that Monday shall be the first day of the week. A week that lies partly in one year and partly in another is assigned a number in the year in which most of its days lie. That means that week number 1 of any year is the week that contains the January 4th.

Syntax

WEEKNUM(Number; Mode)

Number is the internal date number.

Mode sets the start of the week and the calculation type.

1 = Sunday

2 = Monday

Examples

=WEEKNUM("1995-01-01";1) returns 1

=WEEKNUM("1995-01-01";2) returns 52. If the week starts on Monday, Sunday belongs to the last week of the previous year.