@WEEKDAY

Returns the day of the week from a date.

Syntax

@WEEKDAY(V1 / S1 [,V2 ])

Argument Description
V1 or S1

The date, specified as a serial number or a string.

V2

Optional

Week day type.

Logic

The function will return a number representing the day of the week.

The weekday type is an argument that determines the type of return value.

Type Weekday number
0 or omitted Numbers 1 (Sunday), through 7 (Saturday).
1 Numbers 1 (Monday) through 7 (Sunday).
2 Numbers 0 (Monday) through 6 (Sunday).

Examples

@WEEKDAY("01/01/2024") returns 2, Monday

@WEEKDAY("1 Jan 24") returns 2, Monday

@WEEKDAY("1 Jan 2024") returns 2, Monday

@WEEKDAY("01/01/2024",0) returns 2, Monday

@WEEKDAY("01/01/2024",1) returns 1, Monday

@WEEKDAY("01/01/2024",2) returns 0, Monday