#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 193
Default Year formula

I have a row of birth dates on a sheet, and need a formula to determine how
many are over 60 years old.

The cell format for the dates is 11/30/2009

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Year formula

Try
=IF(DATEDIF(A1,TODAY(),"y")=60,"60 or above","")

OR year to year comparison
=IF(YEAR(TODAY())-YEAR(A1)=60,"60 or above","")

--
Jacob


"Robert" wrote:

I have a row of birth dates on a sheet, and need a formula to determine how
many are over 60 years old.

The cell format for the dates is 11/30/2009

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15,768
Default Year formula

Assume your dates are in the range A1:J1

Enter this formula in A2 and copy across to J2:

=DATEDIF(A1,NOW(),"y")

Then to count how many are greater than 60:

=COUNTIF(A2:J2,"60")

--
Biff
Microsoft Excel MVP


"Robert" wrote in message
...
I have a row of birth dates on a sheet, and need a formula to determine how
many are over 60 years old.

The cell format for the dates is 11/30/2009



  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 193
Default Year formula

=if(datedif(D2,today(),"y")=60,"60 or above","")

I tried the above formula and the cell states "60 or above" instead of
giving me a count of people over 60.

Thanks

"Jacob Skaria" wrote:

Try
=IF(DATEDIF(A1,TODAY(),"y")=60,"60 or above","")

OR year to year comparison
=IF(YEAR(TODAY())-YEAR(A1)=60,"60 or above","")

--
Jacob


"Robert" wrote:

I have a row of birth dates on a sheet, and need a formula to determine how
many are over 60 years old.

The cell format for the dates is 11/30/2009

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Year formula

To return the count of say row1 cell references A1:J1 try the below

=SUMPRODUCT((DATEDIF(A1:J1,TODAY(),"y")=60)*(A1:J 10))

--
Jacob


"Robert" wrote:

=if(datedif(D2,today(),"y")=60,"60 or above","")

I tried the above formula and the cell states "60 or above" instead of
giving me a count of people over 60.

Thanks

"Jacob Skaria" wrote:

Try
=IF(DATEDIF(A1,TODAY(),"y")=60,"60 or above","")

OR year to year comparison
=IF(YEAR(TODAY())-YEAR(A1)=60,"60 or above","")

--
Jacob


"Robert" wrote:

I have a row of birth dates on a sheet, and need a formula to determine how
many are over 60 years old.

The cell format for the dates is 11/30/2009

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
convert day of year to numeric value format year+day in 4 digits Kaaren Excel Worksheet Functions 3 February 7th 09 08:37 PM
How do I crate a function for week of year + year in same cell. patty ann Excel Worksheet Functions 1 March 16th 08 06:34 PM
need formula 4 %change on both neg and pos movemnt year to year co suesolotel Excel Discussion (Misc queries) 4 January 13th 08 12:19 AM
Combination Graph with current year and prior year sales JanW Charts and Charting in Excel 2 April 5th 07 09:20 PM
Year-to-date year to date formula Philm Excel Worksheet Functions 1 October 7th 05 02:50 AM


All times are GMT +1. The time now is 09:11 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"