SUMIF help!

  • Thread starter Thread starter louncov
  • Start date Start date
L

louncov

G'day,

I'm familiar with the SUMIF calculation...

A B
1 Peaches 5
2 Pears 10
3 Apples 15
4 Oranges 20
5 Bananas 25

SUMIF(A1:A5,A1,B1:B5) would give me '5', as would
SUMIF(A1:A5,"Peaches",B1:B5). My problem is if I want to know
'Peaches' & 'Pears', something like...

SUMIF(A1:A5,"Pea*",B1:B5)

I know this wouldn't work, as it would search for Pea*, but you get
the idea. I'd be looking for a '15'. Text string variables?

Thanks to all,
Cov.
 
Or

=SUMPRODUCT((A1:A5={"pears","peaches"})*(B1:B5))

--
Best Regards
Leo Heuser
MVP Excel

Followup to newsgroup only please.
 
Leo

That doesn't work for me!! (XL2K)

Andy
Leo Heuser said:
Or

=SUMPRODUCT((A1:A5={"pears","peaches"})*(B1:B5))

--
Best Regards
Leo Heuser
MVP Excel

Followup to newsgroup only please.
 
Back
Top