0% found this document useful (0 votes)
71 views25 pages

Ex6 - Dao Xuan Dat - HS140164

The document discusses various Excel functions for working with dates: - DAYS and NETWORKDAYS count calendar and working days between dates - WORKDAY adds or subtracts working days from a date - EOMONTH returns the last date of a month - EDATE adds or subtracts months from a date - YEARFRAC calculates years between two dates It also covers extracting dates from text and finding nth weekdays of a month.

Uploaded by

Đạt Đào
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as XLSX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
71 views25 pages

Ex6 - Dao Xuan Dat - HS140164

The document discusses various Excel functions for working with dates: - DAYS and NETWORKDAYS count calendar and working days between dates - WORKDAY adds or subtracts working days from a date - EOMONTH returns the last date of a month - EDATE adds or subtracts months from a date - YEARFRAC calculates years between two dates It also covers extracting dates from text and finding nth weekdays of a month.

Uploaded by

Đạt Đào
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as XLSX, PDF, TXT or read online on Scribd
You are on page 1/ 25

Count the number of calendar days between two dates (DAYS function)

Practice Exercises

Calculate the number of calendar days between these dates

Start Date End Date Working days


2/22/2021 3/19/2021 25
2/27/2021 3/27/2021 28
function) To learn more about MS Excel visit www.masterdataanalysis.com
Count the number of working days between two dates (NETWORKDAYS and NETWO

Start Date End Date Working days between dates Formula in column C
5/15/2015 5/29/2015 9 =NETWORKDAYS(A4, B4, F4:F5)
5/15/2015 5/29/2015 13 =NETWORKDAYS.INTL(A5, B5, 11)
5/15/2015 5/29/2015 8 =NETWORKDAYS.INTL(A6, B6, "1010100")

Practice Exercises

Calculate the number of working days between the following dates:

Start Date End Date Working days


2/22/2021 3/19/2021 20
2/27/2021 3/27/2021 20

Calculate the number of working days between the following dates assuming that weekends are only Friday

Start Date End Date Working days


2/25/2021 3/15/2021 16
2/12/2021 4/5/2021 45

Calculate the number of working days between the following dates assuming that weekends are Monday and Friday

Start Date End Date Working days


3/3/2021 3/22/2021 15
2/13/2021 3/23/2021 27
ORKDAYS and NETWORKDAYS.INTL Functions) To learn more about MS Excel visit

Holidays
5/22/2015
5/26/2015

s are only Friday

s are Monday and Friday


more about MS Excel visit www.masterdataanalysis.com
Add a number of working days to a date (WORKDAY Function)

Start Date Days Date after working days Formula in column C


5/15/2015 10 6/2/2015 =WORKDAY(A4, B4, F4:F5)
5/15/2015 10 5/27/2015 =WORKDAY.INTL(A5, B5, 13)
5/15/2015 10 5/31/2015 =WORKDAY.INTL(A6, B6, "1010100")
5/15/2015 -5 5/8/2015 =WORKDAY(A7, B7)

Practice Exercises

Find the date after working days in the following dates:

Start Date Days Date after working days


3/17/2021 13 4/5/2021
2/3/2021 -4 1/28/2021

Find the date after working days in the following dates assuming that weekend is only on Wednesday

Start Date Days Date after working days


3/7/2021 14 3/23/2021
2/7/2021 7 2/15/2021

Find the date after working days in the following dates assuming that weekend is on Tuesday and Saturday

Start Date Days Date after working days


4/2/2021 9 4/15/2021
3/9/2021 29 4/19/2021
To learn more about MS Excel visiwww.masterdataanalysis.com

Holidays
5/22/2015
5/26/2015
Monday Tuesday Wednesday Thursday Friday Saturday
1 0 1 0 1 0
Sunday
0
Determining the end of a month (EOMONTH Function) To learn more about MS

Start Date Months after Last day of month Formula in column C


5/15/2015 0 5/31/2015 =EOMONTH(A4, B4)
5/15/2015 3 8/31/2015 =EOMONTH(A5, B5)
5/15/2015 -3 2/28/2015 =EOMONTH(A6, B6)

Practice Exercises

Find the last day of the month in following data assuming that we have to find last day of month, two months after start da

Start Date Months after Last day of month


1/28/2021 2 3/31/2021
4/23/2021 2 6/30/2021

Find the last day of the month in following data assuming that we have to find last day of month, three months before start

Start Date Months before Last day of month


1/31/2021 3 10/31/2020
4/28/2021 3 1/31/2021
To learn more about MS Excel viwww.masterdataanalysis.com

two months after start date.

three months before start date.


Adding n months to a given date (EDATE Function) To learn more about MS

Start Date Months after Date after months Formula in column C


5/15/2015 0 5/15/2015 =EDATE(A4, B4)
5/15/2015 3 8/15/2015 =EDATE(A5, B5)
5/15/2015 -3 2/15/2015 =EDATE(A6, B6)

Practice Exercises

Find the date after months in following data assuming that we have to find the data which is one month before the start da

Start Date Months before Date after months


2/20/2021 1 1/20/2021
3/9/2021 1 2/9/2021

Find the date after months in following data assuming that we have to find the data which is four months after the start dat

Start Date Months before Date after months


2/16/2021 -4 6/16/2021
3/13/2021 -4 7/13/2021
To learn more about MS Excel viwww.masterdataanalysis.com

month before the start date:

months after the start date:


Determining the first day of a month (EOMONTH Function) To learn more about M

Start Date Months after First day of month Formula in column C


5/15/2015 0 5/1/2015 =EOMONTH(A4, B4 - 1) + 1
5/15/2015 3 8/1/2015 =EOMONTH(A5, B5 - 1) + 1

Practice Exercises

Find the first day of month in following data assuming that we have to find first date of month after five months of start dat

Start Date Months after First day of month


1/18/2015 5 6/1/2015
3/10/2015 5 8/1/2015

Find the first day of month in following data assuming that we have to find first date of month before five months of start d

Start Date Months after First day of month


5/21/2015 -5 1/1/2015
7/11/2015 -5 3/1/2015
To learn more about MS Excel viwww.masterdataanalysis.com

r five months of start date:

re five months of start date:


Adding n years to the current date (EDATE Function) To learn more about MS Excel vi

Start Date Years after (n) Date after n years Formula in column C
5/15/2015 0 5/15/2015 =EDATE(A4, 12 * B4)
5/15/2015 3 5/15/2018 =EDATE(A5,12* B5)

Practice Exercises

Find the date after working days in following table assuming that we have to find date after working days before two month

Start Date Years after (n) Date after n years


3/7/2021 -0.16666666667 1/7/2021
2/26/2021 -0.16666666667 12/26/2020

Find the date after working days in following table assuming that we have to find date after working days before two month

Start Date Years after (n) Date after n years


4/12/2021 -0.16666666667 2/12/2021
1/27/2021 -0.16666666667 11/27/2020
more about MS Excel viwww.masterdataanalysis.com

ing days before two months of start date:

ing days before two months of start date:


Calculating years between two dates (YEARFRAC and FLOOR Functions)

Start Date End Date Years Formula in column C


1/1/1995 10/4/2015 20.76 =YEARFRAC(A4, B4)

Practice Exercises

Find the years between the two dates given in the following data:

Start Date End Date Years


6/8/2018 10/21/2019 1.37
3/22/2010 9/12/2015 5.47
To learn more about MS Excel viwww.masterdataanalysis.com
Extracting a date serial number from a date formatted as text (DATEVALUE and SUB

Text Date Date Formula in column C


November 15, 2015 15-Nov-15 =DATEVALUE(A4)
15-Nov-15 15-Nov-15 =DATEVALUE(A5)
2015-11-15 15-Nov-15 =DATEVALUE(A6)
15.11.15 15-Nov-15 =DATEVALUE(SUBSTITUTE(A7, ".", "/"))

Practice Exercises

Find the date serial number from text date given in the data below:

Text Date Date


November 26, 2015 26-Nov-15
02-March-97 2-Mar-97
2004-02-13 13-Feb-04
8.10.12 8-Oct-12 (Hint: Use SUBSITUTE Function)
ormatted as text (DATEVALUE and SUBSTITUTEFunctions) To learn more about MS
To learn more about MS Excel viwww.masterdataanalysis.com
Determining the Nth Weekday of a month (Example: The first (1st) Monday of a mont

Date Nth Day Date after working days


5/15/2015 1 2 4-May-15
5/15/2015 2 2 11-May-15
5/15/2015 3 2 18-May-15
5/15/2015 3 3 19-May-15
5/15/2015 3 4 20-May-15

Practice Exercises

Find the 2nd Monday of a month from following data:

Date Nth Day Date after working days


10/3/2015 2 2 12-Oct-15
11/8/2015 2 2 9-Nov-15
12/30/2015 2 2 14-Dec-15
7/26/2015 2 2 13-Jul-15
12/11/2015 2 2 14-Dec-15

Find the 3rd Sunday of a month from following data:

Date Nth Day Date after working days


10/3/2015 3 1 18-Oct-15
11/8/2015 3 1 15-Nov-15
12/30/2015 3 1 20-Dec-15
7/26/2015 3 1 19-Jul-15
12/11/2015 3 1 20-Dec-15

Find the 4th Friday of a month from following data:

Date Nth Day Date after working days


10/3/2015 4 6 23-Oct-15
11/8/2015 4 6 27-Nov-15
12/30/2015 4 6 25-Dec-15
7/26/2015 4 6 24-Jul-15
12/11/2015 4 6 25-Dec-15
day of a month (Example: The first (1st) Monday of a month) (EOMONTH, WEEKDAY, MONT

Formula in column B Comment


=EOMONTH(A4, -1) + 1 + 7*B4 - WEEKDAY(DATE(YEAR(A4), MONTH(A4), 8 - C4)) 1st Monday
=EOMONTH(A5, -1) + 1 + 7*B5 - WEEKDAY(DATE(YEAR(A5), MONTH(A5), 8 - C5)) 2nd Monday
=EOMONTH(A6, -1) + 1 + 7*B6 - WEEKDAY(DATE(YEAR(A6), MONTH(A6), 8 - C6)) 3rd Monday
=EOMONTH(A7, -1) + 1 + 7*B7 - WEEKDAY(DATE(YEAR(A7), MONTH(A7), 8 - C7)) 3rd Tuesday
=EOMONTH(A8, -1) + 1 + 7*B8 - WEEKDAY(DATE(YEAR(A8), MONTH(A8), 8 - C8)) 3er Wednesday

following data:

ollowing data:

lowing data:
TH, WEEKDAY, MONTH Functions) To learn more about MS Excel viwww.masterdataanalysis.co
www.masterdataanalysis.com

You might also like