Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Data as below
Comp A 10 Comp B 50 Comp C 80 Comp D 100 Assume data starts from column A, I want to sum data in column B when column A is either Comp A or Comp B (answer would be 90). Many posts asked for 2 criteria is usually AND so those formulea don't work out so far. Thanks in advance |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
hi
try something like this. =SUMIF(A2:A5,"Comp A",B2:B5)+SUMIF(A2:A5,"Comp B",B2:B5) and i think it adds up to 60. regards FSt1 "IA_sit" wrote: Data as below Comp A 10 Comp B 50 Comp C 80 Comp D 100 Assume data starts from column A, I want to sum data in column B when column A is either Comp A or Comp B (answer would be 90). Many posts asked for 2 criteria is usually AND so those formulea don't work out so far. Thanks in advance |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Answer for a & b would b2 60. For a & c it would be 90
=SUMPRODUCT((G1:G21={"comp a","comp b"})*H1:H21) -- Don Guillett Microsoft MVP Excel SalesAid Software "IA_sit" wrote in message ... Data as below Comp A 10 Comp B 50 Comp C 80 Comp D 100 Assume data starts from column A, I want to sum data in column B when column A is either Comp A or Comp B (answer would be 90). Many posts asked for 2 criteria is usually AND so those formulea don't work out so far. Thanks in advance |
#4
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
either Comp A or Comp B (answer would be 90).
I think the correct answer based on your sample would be 60. Try one of these: =SUM(SUMIF(A1:A4,{"Comp A","Comp B"},B1:B4)) =SUMIF(A1:A4,"Comp A",B1:B4)+SUMIF(A1:A4,"Comp B",B1:B4) -- Biff Microsoft Excel MVP "IA_sit" wrote in message ... Data as below Comp A 10 Comp B 50 Comp C 80 Comp D 100 Assume data starts from column A, I want to sum data in column B when column A is either Comp A or Comp B (answer would be 90). Many posts asked for 2 criteria is usually AND so those formulea don't work out so far. Thanks in advance |
#5
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
=SUMPRODUCT((A1:A4="Comp "&{"A","B"})*B1:B4)
"IA_sit" wrote: Data as below Comp A 10 Comp B 50 Comp C 80 Comp D 100 Assume data starts from column A, I want to sum data in column B when column A is either Comp A or Comp B (answer would be 90). Many posts asked for 2 criteria is usually AND so those formulea don't work out so far. Thanks in advance |
#6
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Array formula. (Ctrl+Shift+Enter)
=SUM(((A1:A4="Comp A")+(A1:A4="Comp B"))*B1:B4) John Ο χρήστης "IA_sit" *γγραψε: Data as below Comp A 10 Comp B 50 Comp C 80 Comp D 100 Assume data starts from column A, I want to sum data in column B when column A is either Comp A or Comp B (answer would be 90). Many posts asked for 2 criteria is usually AND so those formulea don't work out so far. Thanks in advance |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How do I use Sumif and have the criteria be 10 AND <26? | Excel Discussion (Misc queries) | |||
SUMIF with more than one criteria | Excel Discussion (Misc queries) | |||
sumif criteria | Excel Discussion (Misc queries) | |||
nested sumif or sumif with two criteria | Excel Worksheet Functions | |||
Sumif() with criteria | Excel Worksheet Functions |