The WEEKDAY function is among the functions in the date and time category commonly utilized in Excel. The Weekday function returns a positive integer value, allowing you to adjust options to set the starting day of the week as either Sunday or Monday, with the ordinal number for the starting day of the week being 0 or 1.
Using the WEEKDAY Function in Excel
Using the WEEKDAY Function in Excel
1. Description and Syntax
This function calculates the day of the week for a corresponding date. The returned value is an integer ranging from 1 (Sunday) to 7 (Saturday).
Syntax:
WEEKDAY(Serial_Number,[Return_Type])
Where:
- Serial_number: The date value you want to determine the day of the week for, this is a required parameter.
- Return_type: The value determining the type of return, an optional parameter with the following values:
Note:
- Excel stores dates in serial numbers for convenient calculations.
- If Serial_Number is outside the basic range -> the function returns an error value #VALUE!
- If Return_Type is outside the defined values above -> the function returns an error value #NUM!
2. Specific Scenario Examples:
Suppose you need to find the day of the week for the dates in the table below using different Return_Type values:
Step 1: In the cell where you want to calculate, enter the formula: =WEEKDAY(B3,C3)
Step 2: Press Enter -> the returned value is:
Step 3: With the same date value but different Return_Type settings -> will yield different results:
In case you input incorrect date data, here entering the month value =15 -> the function returns an error value #VALUE!
If the Return_Type value exceeds its range of values -> the function returns an error value #NUM!
Above, Mytour has introduced and guided you on how to use the WEEKDAY function in Excel along with some very specific examples. Basically, you just need to remember the syntax of this function as WEEKDAY(Serial_Number,[Return_Type]), where Serial_number is the date value you want to determine the day of the week for, and Return_type is the value determining the type of return.
Wishing you success and quickly memorizing the Weekday function formula to serve your calculations when working on Excel.
The Concatenate function is a helper function to concatenate individual characters into a single string, you can use the Concatenate function to merge cells if the cells simultaneously contain different characters.