Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
If I have two column as below:
(ColumnA) (Column B) 1. Apple 35 2. Orange 5 3. Banana 9 4. Pear 25 5. Banana 18 6. Apple 56 7. Orange 36 8. watermelon 66 9. Orange 14 10.Apple 5 If I use SumIf like this =SUMIF(A1:A5,"Banana",B1:B5), it only come up 18+9 = 27. How can I sum up more than two items in the ColumA, like sum up "Pear" + "Apple" +"Orange" together. |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
You could use multiple =sumif()'s:
=SUMIF(A1:A5,"apple",B1:B5) +SUMIF(A1:A5,"pear",B1:B5) +SUMIF(A1:A5,"orange",B1:B5) Or you could use something like: =sum(SUMIF(A1:A5,{"apple","pear","orange"},B1:B5)) Adjust your range...I bet it doesn't stop with row 5. sumif wrote: If I have two column as below: (ColumnA) (Column B) 1. Apple 35 2. Orange 5 3. Banana 9 4. Pear 25 5. Banana 18 6. Apple 56 7. Orange 36 8. watermelon 66 9. Orange 14 10.Apple 5 If I use SumIf like this =SUMIF(A1:A5,"Banana",B1:B5), it only come up 18+9 = 27. How can I sum up more than two items in the ColumA, like sum up "Pear" + "Apple" +"Orange" together. -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
sumif for multi conditions. i.e sumif(A1:A10,"Jon" and B1:B10,"A" | Excel Worksheet Functions | |||
Embedding a Sumif in a sumif | Excel Worksheet Functions | |||
SUMIF | Excel Discussion (Misc queries) | |||
nested sumif or sumif with two criteria | Excel Worksheet Functions | |||
SUMIF - Range name to used for the "sum_range" portion of a SUMIF function | Excel Worksheet Functions |