filmov
tv
Google Sheets | WORKDAY | WORKDAY.INTL | Function | Get Next Working Day | Spreadsheet Tutorial

Показать описание
The Google Sheets WORKDAY and WORKDAY.INTL functions assist you to get the nearest working day from a specified start date and after a specified number of working days. For dates, such as the project completion date, the working date after a vacation, and next meeting date, either or both of these functions can be useful.
A difference between the two functions is that WORKDAY assumes a two-day weekend of Saturday and Sunday. With WORKDAY.INTL, you can specify whether the weekend is one or two days. Further, this function allows you two specify the weekend day(s) or non-working day(s), other than a Saturday or Sunday.
A trait common to both of these Google Sheets functions is that you can specify the holidays to be taken into account for getting the next working day.
Here is the format of the WORKDAY function formula:
=WORKDAY(start_date, num_days, [holidays])
Start the formula with an equal-to symbol.
WORKDAY is the name of the function.
start_date is the date from which to begin counting for getting the next
working day.
num_days, if positive, is the number of working days to move forward from
the start_date, before getting the next working day. If negative, num_days is the number of working days to move backward from the start_date.
holidays is optional, and is a list of holidays that the WORKDAY function should take into account to calculate the next working day.
Let's look at an example of the WORKDAY function formula:
=WORKDAY("8/27/2021", 5, C5:C13)
The range C5:C13 in the spreadsheet is the list of holidays in a date format.
The function returns 9/3/2021 as the next working day.
Here is the format of the WORKDAY.INTL function formula:
=WORKDAY.INTL(start_date, num_days, [weekend], [holidays])
The only difference between the WORKDAY.INTL and WORKDAY functions is that the former function has the optional attribute, weekend.
The weekend attribute takes either a number or string as its value.
The number values representing weekend(s) are:
1 = Saturday and Sunday
2 = Sunday and Monday
3 = Monday and Tuesday
4 = Tuesday and Wednesday
5 = Wednesday and Thursday
6 = Thursday and Friday
7 = Friday and Saturday
11 = Sunday is the only weekend
12 = Monday is the only weekend
13 = Tuesday is the only weekend
14 = Wednesday is the only weekend
15 = Thursday is the only weekend
16 = Friday is the only weekend
17 = Saturday is the only weekend
The string values for representing weekends:
Using seven 0's or 1's or a combination of 0's and 1's weekends can be specified. The first number in the seven-digit set represents Monday and the last digit is Sunday. Further, a 0 means it is a working day and 1 means it is a weekend day.
Here are two examples of string values for representing weekends:
0000001 means Sunday is the weekend day.
0000011 means Saturday and Sunday are the weekend days.
1000000 means Monday is the weekend day.
Let's look at an example of the WORKDAY.INTL function formula:
=WORKDAY.INTL("8/27/2021", 15, 1, C5:C13)
Here the value 1 of the num_days attribute represents Sunday as the weekend. As before, the spreadsheet range C5:C13 is the list of holidays.
The function returns 9/20/2021 as the next working day.
Take a look at this video tutorial, which gives the steps to use the Google
Sheets WORKDAY and WORKDAY.INTL functions with examples.
A difference between the two functions is that WORKDAY assumes a two-day weekend of Saturday and Sunday. With WORKDAY.INTL, you can specify whether the weekend is one or two days. Further, this function allows you two specify the weekend day(s) or non-working day(s), other than a Saturday or Sunday.
A trait common to both of these Google Sheets functions is that you can specify the holidays to be taken into account for getting the next working day.
Here is the format of the WORKDAY function formula:
=WORKDAY(start_date, num_days, [holidays])
Start the formula with an equal-to symbol.
WORKDAY is the name of the function.
start_date is the date from which to begin counting for getting the next
working day.
num_days, if positive, is the number of working days to move forward from
the start_date, before getting the next working day. If negative, num_days is the number of working days to move backward from the start_date.
holidays is optional, and is a list of holidays that the WORKDAY function should take into account to calculate the next working day.
Let's look at an example of the WORKDAY function formula:
=WORKDAY("8/27/2021", 5, C5:C13)
The range C5:C13 in the spreadsheet is the list of holidays in a date format.
The function returns 9/3/2021 as the next working day.
Here is the format of the WORKDAY.INTL function formula:
=WORKDAY.INTL(start_date, num_days, [weekend], [holidays])
The only difference between the WORKDAY.INTL and WORKDAY functions is that the former function has the optional attribute, weekend.
The weekend attribute takes either a number or string as its value.
The number values representing weekend(s) are:
1 = Saturday and Sunday
2 = Sunday and Monday
3 = Monday and Tuesday
4 = Tuesday and Wednesday
5 = Wednesday and Thursday
6 = Thursday and Friday
7 = Friday and Saturday
11 = Sunday is the only weekend
12 = Monday is the only weekend
13 = Tuesday is the only weekend
14 = Wednesday is the only weekend
15 = Thursday is the only weekend
16 = Friday is the only weekend
17 = Saturday is the only weekend
The string values for representing weekends:
Using seven 0's or 1's or a combination of 0's and 1's weekends can be specified. The first number in the seven-digit set represents Monday and the last digit is Sunday. Further, a 0 means it is a working day and 1 means it is a weekend day.
Here are two examples of string values for representing weekends:
0000001 means Sunday is the weekend day.
0000011 means Saturday and Sunday are the weekend days.
1000000 means Monday is the weekend day.
Let's look at an example of the WORKDAY.INTL function formula:
=WORKDAY.INTL("8/27/2021", 15, 1, C5:C13)
Here the value 1 of the num_days attribute represents Sunday as the weekend. As before, the spreadsheet range C5:C13 is the list of holidays.
The function returns 9/20/2021 as the next working day.
Take a look at this video tutorial, which gives the steps to use the Google
Sheets WORKDAY and WORKDAY.INTL functions with examples.