Home |
Search |
Today's Posts |
|
#1
![]() |
|||
|
|||
![]()
When using SUMIF, is the [sum_range] restricted to values in a single column?
To explain my question I have the following data: ADD LIST A LIST B Y 120 0 85 217 Y 0 50 Y 40 92 When I insert the formula "=SUMIF($A$2:$A$5,"Y",$B$2:$C$5)" I am getting the value 160 because the sum_range of $B$2:$C$5 is returning only the sum of values in column B. What I would like is to see a value of 302. Is it possible for the [sum_range] to be a range across multiple contiguous columns? Thanks in advance |
#2
![]() |
|||
|
|||
![]()
You said it doesn't work, so evidently the answer to your question is NO.
You can use 2 SUMIF FORMULAs, i.e. =SUMIF($A$2:$A$5,"Y",$B$2:$B$5)+SUMIF($A$2:$A$5,"Y ",$C$2:$C$5) or =SUMPRODUCT(($A$2:$A$5="Y")*($B$2:$C$5)) On Tue, 16 Nov 2004 17:23:02 -0800, "Kevin B" <Kevin wrote: When using SUMIF, is the [sum_range] restricted to values in a single column? To explain my question I have the following data: ADD LIST A LIST B Y 120 0 85 217 Y 0 50 Y 40 92 When I insert the formula "=SUMIF($A$2:$A$5,"Y",$B$2:$C$5)" I am getting the value 160 because the sum_range of $B$2:$C$5 is returning only the sum of values in column B. What I would like is to see a value of 302. Is it possible for the [sum_range] to be a range across multiple contiguous columns? Thanks in advance |
#3
![]() |
|||
|
|||
![]()
Myrna
Thank you, the SUMPRODUCT solution is perfect. "Myrna Larson" wrote: You said it doesn't work, so evidently the answer to your question is NO. You can use 2 SUMIF FORMULAs, i.e. =SUMIF($A$2:$A$5,"Y",$B$2:$B$5)+SUMIF($A$2:$A$5,"Y ",$C$2:$C$5) or =SUMPRODUCT(($A$2:$A$5="Y")*($B$2:$C$5)) On Tue, 16 Nov 2004 17:23:02 -0800, "Kevin B" <Kevin wrote: When using SUMIF, is the [sum_range] restricted to values in a single column? To explain my question I have the following data: ADD LIST A LIST B Y 120 0 85 217 Y 0 50 Y 40 92 When I insert the formula "=SUMIF($A$2:$A$5,"Y",$B$2:$C$5)" I am getting the value 160 because the sum_range of $B$2:$C$5 is returning only the sum of values in column B. What I would like is to see a value of 302. Is it possible for the [sum_range] to be a range across multiple contiguous columns? Thanks in advance |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
what formula do i put for column m = column k minus column l in e. | Excel Discussion (Misc queries) | |||
how to fit my column unmoved eventhough i scroll down? | New Users to Excel | |||
Copying the contents of a column into a chart | Excel Worksheet Functions | |||
How to calculate the data in excel 2002 including only the last 9. | Excel Worksheet Functions | |||
How Do I created a nested sumif - if this column has this and thi. | Excel Worksheet Functions |