SUMIF Help

S

Steve M

I want to sum the values in rows 2 to 100 in column G where the text in
columns D or E match the text in a given cell (say F3). I would like to be
able to change the text in cell F3 and still get the sum from G2 thru G100
where text in columns D or E match F3.
 
J

Jarek Kujawa

=SUM(IF(($D$2:$D$100=F3)+($E$2:$E$100=F3),$G$2:$G$100))

CTRL+SHIFT+ENTER (instead of using ENTER only) this formula as it is
an array-formula

after correct insertion the formula will look like

{=SUM(IF(($D$2:$D$100=F3)+($E$2:$E$100=F3),$G$2:$G$100))}


HIH
 
A

Ashish Mathur

Hi,

Try this

=sumproduct((D2:E100=F3)*(G2:G100)). However, if the value specified in F3,
appears in the same row in D2:E100, then it would get summed up twice

--
Regards,

Ashish Mathur
Microsoft Excel MVP
www.ashishmathur.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top