- Tutorial: Using the NETWORKDAYS Function
- NETWORKDAYS Function Syntax and Arguments
- The math behind the function
Tutorial: Using the NETWORKDAYS Function
Use the NETWORKDAYS function in Google Sheets to calculate the number of working days or working days between the specified start and end dates. With this function, weekends (Saturday and Sunday) are automatically removed from the total. Certain days, such as holidays, can also be omitted.
NETWORKDAYS Function Syntax and Arguments
Function syntax refers to the layout of the function and includes the function name, parentheses, and arguments.
The syntax for the NETWORKDAYS function is:
= ЧИСТРАБДНИ (дата_начала, дата_окончания, праздники)
- Starting date – (mandatory) start date of the selected period
- End date – (mandatory) the end date of the selected period
For both arguments, use date values, serial numbers, or a cell reference that contains the location of that data on the worksheet.
- Holidays – (optional) one or more extra dates that are excluded from the total number of working days.
Holiday dates can be date values entered directly into a formula, or cell references to find data in a worksheet.
Since NETWORKDAYS does not automatically convert data to date formats, date values entered directly into the function must be entered for all three arguments using the functions DATE or DATEVALUE avoid calculation errors.
Meaning! An error value is returned if an argument contains an invalid date.
The math behind the function
Google Sheets processes its calculations in two steps. First, it estimates the direct number of business days between two specified dates.
After that it removes any date given in the argument holidays if the date falls on a weekday. For example, if the period includes two holidays (for example, Memorial Day and Independence Day in the United States), and both days fall on a weekday, the original number between the dates is reduced by two and the answer is shown in the table.