0% found this document useful (0 votes)
22 views

Date Functions - Notes

made by corporate bridge

Uploaded by

dibyendu
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
22 views

Date Functions - Notes

made by corporate bridge

Uploaded by

dibyendu
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

DATE FUNCTIONS- DATE/DATEDIF/NETWORKDAYS/TODAY/WEEKDAY/WORKDAY/YEARFRAC

DATE
WHY YOU NEED TO KNOW THIS?

Many a times there is a need to write the date in standard format

WHAT DOES IT DO?

This function creates a real date by using three normal numbers typed into separate cells

SYNTAX

=DATE(year,month,day)
The result will normally be displayed in the dd/mm/yy format
By using the Format,Cells,Number,Date command the format can be changed

EXAMPLE

3
4
5
6

C
Day
13
14
20

D
Month
12
12
12

E
Year
7
8
97

F
Date

12/13/07 =DATE(E4,D4,C4)
14-Dec-08 =DATE(E5,D5,C5)
December 20, 1997 =DATE(E6,D6,C6)

DATEDIF
WHY YOU NEED TO KNOW THIS?

When you need to know the exact difference between two dates in days, months or years

WHAT DOES IT DO?

This function calculates the difference between two dates


It can show the result in weeks, months or years

SYNTAX

=DATEDIF(FirstDate,SecondDate,"Interval")
FirstDate : This is the earliest of the two dates
SecondDate : This is the most recent of the two dates
"Interval" : This indicates what you want to calculate
o "d: Days between the two dates
o "m: Months between the two dates
o "y: Years between the two dates
o "yd: Days between the dates, as if the dates were in the same year
o "ym: Months between the dates, as if the dates were in the same year
o "md: Days between the two dates, as if the dates were in the same month and year

EXAMPLE

www.educorporatebridge.com

3
4
5
6
7
8
9

C
FirstDate
1-Jan-06
1-Jan-06
1-Jan-06
1-Jan-06
1-Jan-06
1-Jan-06

D
SecondDate
10-May-07
10-May-07
10-May-07
10-May-07
10-May-07
10-May-07

E
Interval
days
months
years
yeardays
yearmonths
monthdays

F
Difference
494
16
1
129
4
9

=DATEDIF(C4,D4,"d")
=DATEDIF(C5,D5,"m")
=DATEDIF(C6,D6,"y")
=DATEDIF(C7,D7,"yd")
=DATEDIF(C8,D8,"ym")
=DATEDIF(C9,D9,"md")

NETWORKDAYS
WHY YOU NEED TO KNOW THIS?

When you need to know the number of working days between two given days
Stock market is closed on public holidays and hence, used for calculation of active days

WHAT DOES IT DO?

This function will calculate the number of working days between two dates
It will exclude weekends and any holidays

SYNTAX

=NETWORKDAYS(StartDate,EndDate,Holidays)
Holidays: This is a list of dates which will be excluded from the calculation, such as Xmas and Bank holidays

EXAMPLE

27
28
29
30
31
32
33
34
35
36

B
Start Date
Tue 02-Mar-04
Tue 02-Mar-04
Fri 27-Apr-07

Bank Holiday
Xmas
New Year
New Year

C
End Date
Thu 06-Mar-08
Thu 13-Mar-08
Tue 01-May-07

D
Work Days
1044
1049
2

=NETWORKDAYS(B28,C28,C33:C37)
=NETWORKDAYS(B29,C29,C33:C37)
=NETWORKDAYS(B30,C30,C33:C37)

Holidays
1-May-07
25-Dec-07
1-Jan-07
1-Jan-08

TODAY
WHY YOU NEED TO KNOW THIS?

When you need to do valuations as of the most current date, this function becomes very helpful

WHAT DOES IT DO?

Use this to show the current date

SYNTAX

=TODAY()

www.educorporatebridge.com

The result will normally be displayed using the DD-MMM-YY format

EXAMPLE

3
4

C
Today Is
28-Apr-08

19
20
21

C
Date
1-Jan-97
10-Aug-97

D
=TODAY()

D
Days Since
4135
3914

E
=TODAY()-C20
=TODAY()-C21

WEEKDAY
WHY YOU NEED TO KNOW THIS?

To check if the day is market holiday (Saturday or Sunday)

WHAT DOES IT DO?

This function shows the day of the week from a date

SYNTAX

=WEEKDAY(Date,Type)
Type: This is used to indicate the week day numbering system
o 1 : will set Sunday as 1 through to Saturday as 7
o 2 : will set Monday as 1 through to Sunday as 7
o 3 : will set Monday as 0 through to Sunday as 6
o If no number is specified, Excel will use 1

EXAMPLE

3
4
5
6
7
8

C
Date
Thu 01-Jan-98
Thu 01-Jan-98
Thu 01-Jan-98
Thu 01-Jan-98
Thu 01-Jan-98

D
Weekday
5
5
5
4
3

E
=WEEKDAY(C4)
=WEEKDAY(C5)
=WEEKDAY(C6,1)
=WEEKDAY(C7,2)
=WEEKDAY(C8,3)

WORKDAY
WHY YOU NEED TO KNOW THIS?

Used for calculating project completion date / invoice date

WHAT DOES IT DO?

Use this function to calculate a past or future date based on a starting date and a specified number of days

www.educorporatebridge.com

The function excludes weekends and holidays

SYNTAX

=WORKDAY(StartDate,Days,Holidays)
The result will normally be shown as a number which can be formatted to a normal date by using Format,
Cells, Number or Date

EXAMPLE
23
24
25
26
27
28
29
30

D
Order Date
Fri 02-Feb-07
Mon 17-Dec-07
Holidays
Tue 01-May-07
Tue 25-Dec-07
Tue 01-Jan-08

E
Delivery Days
2
28

F
Delivery Date
Tue 06-Feb-07
Mon 28-Jan-08

=WORKDAY(D25,E25,D28:D32)
=WORKDAY(D25,E25,D28:D32)

Bank Holiday
Xmas
New Year

YEARFRAC
WHY YOU NEED TO KNOW THIS?

Used for calculation of the time period between two dates (calculating Net Present Value or IRR)

WHAT DOES IT DO?

This function calculates the difference between two dates and expresses the result as a decimal fraction

SYNTAX

=YEARFRAC(StartDate,EndData,Basis)
Basis : Defines the calendar system to be used in the function
o 0 : or omitted US style 30 days per month divided by 360
o 1 : 29 or 30 or 31 days per month divided by 365
o 2 : 29 or 30 or 31 days per month divided by 360
o 3 : 29 or 30 0r 31 days per month divided by 365
o 4 : European 29 or 30 or 31 days divided by 360

EXAMPLE

3
4
5
6

C
Start Date
1-Jan-98
1-Jan-98
1-Jan-98

D
End Date
1-Apr-98
31-Dec-98
1-Apr-98

E
Fraction
0.25
1
25%

F
=YEARFRAC(C4,D4)
=YEARFRAC(C5,D5)
=YEARFRAC(C6,D6)

www.educorporatebridge.com

You might also like