Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Space Elf
 
Posts: n/a
Default Criteria in SUMIF

I'm trying to use SUMIF to total a range of numbers. I'd like to get the
results for a particular month but I can't figure out how to use a date range
under criteria. It only seems to let me choose greater than or less than one
date.

Is there a way to use an equivalent criterea argument like 4/30/2005 &
<6/1/2005
in order to add all values in a column when the corresponding date column is
in the month of May 2005?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
bpeltzer
 
Posts: n/a
Default Criteria in SUMIF

To use a range of values you can either use sumproduct or use two sumif
calculations. My preference is for the latter:
=sumif(a:a,"=" & date(2005,5,1), b:b) - sumif(a:a,"=" & date(2005,6,1),
b:b).
The first part adds up everything from May 1 and later; the second takes
out everything from June 1 and later, leaving only May activity.
--Bruce

"Space Elf" wrote:

I'm trying to use SUMIF to total a range of numbers. I'd like to get the
results for a particular month but I can't figure out how to use a date range
under criteria. It only seems to let me choose greater than or less than one
date.

Is there a way to use an equivalent criterea argument like 4/30/2005 &
<6/1/2005
in order to add all values in a column when the corresponding date column is
in the month of May 2005?

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Ron Coderre
 
Posts: n/a
Default Criteria in SUMIF

Try something like this:
=SUMPRODUCT(--(A1:A100<DATEVALUE("6/1/2005"))*(A1:A100=DATEVALUE("5/1/2005"))*(B1:B100))

Does that help?

***********
Regards,
Ron

XL2002, WinXP-Pro


"Space Elf" wrote:

I'm trying to use SUMIF to total a range of numbers. I'd like to get the
results for a particular month but I can't figure out how to use a date range
under criteria. It only seems to let me choose greater than or less than one
date.

Is there a way to use an equivalent criterea argument like 4/30/2005 &
<6/1/2005
in order to add all values in a column when the corresponding date column is
in the month of May 2005?

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
How do I use the sumif if I have multiple criteria (i.e. greater . Kellyatisl Excel Worksheet Functions 3 June 4th 06 06:33 AM
Multiple SUMIF Criteria azazel Excel Worksheet Functions 3 November 10th 05 08:31 PM
SUMIF with Mutiple Ranges & Criteria PokerZan Excel Discussion (Misc queries) 5 August 4th 05 10:31 PM
"criteria" in a sumif refering to the value in another cell mark Excel Discussion (Misc queries) 1 January 31st 05 07:39 PM
Can I use a cell reference in the criteria for the sumif function. Number Cruncher Excel Worksheet Functions 2 November 4th 04 07:52 PM


All times are GMT +1. The time now is 06:09 PM.

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

About Us

"It's about Microsoft Excel"