Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have column A with some numbers and column B, where some cells are empty and some cells contains '+'. And I want to sum cells from Column A, but only cells in rows where B column contains '+'.

For example:

A    B
1    +
2    
3    +
4    

So I want to sum 1 and 3 and get 4.

Can anybody help me?

share|improve this question

migrated from stackoverflow.com Nov 19 '12 at 15:47

This question came from our site for professional and enthusiast programmers.

    
Define "summarize" please. – Marc Nov 13 '12 at 21:58
    
Get sum. 1 + 3. – Igor Ryzhov Nov 13 '12 at 21:59
up vote 1 down vote accepted

SUMIF should do it, as in:

=sumif(B1:B4,"+",A1:A4)

share|improve this answer
    
Thank you, it works! – Igor Ryzhov Nov 13 '12 at 22:02

Here ya go:

=SUMIF(B1:B4,"+",A1:A4)
share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .