Using "or" in criteria

M

Maureen

I have a formula that allows for individual criteria:

=SUM(('Test Map'!G2:G124="R")*('Test Map'!I2:I124="Anchor"))

I would like the 2nd part of the formula to allow for either "Anchor" or "A".

Any ideas how I can incorporate?
 
S

Sheeloo

Why not use
=SUM(('Test Map'!G2:G124="R")*('Test Map'!I2:I124="Anchor"))
+ SUM(('Test Map'!G2:G124="R")*('Test Map'!I2:I124="A"))
 
B

Bernie Deitrick

Use + as Or within an array formula:

=SUM(('Test Map'!G2:G124="R")*(('Test Map'!I2:I124="Anchor")+('Test Map'!I2:I124="A")))


HTH,
Bernie
MS Excel MVP
 
S

Shane Devenshire

HI,

I would switch from SUM to SUMPRODUCT so you don't need to array enter it:

=SUMPRODUCT(('Test Map'!G2:G124="R")*(('Test Map'!I2:I124="Anchor")+('Test
Map'!I2:I124="A")))
 
F

francis

I would prefer using Sumproduct

=SUMPRODUCT(('Test Map'!G2:G124="R")*(('Test Map'!I2:I124="Anchor")+('Test
Map'!I2:I124="A")))


--
Hope this is helpful

Pls click the Yes button below if this post provide answer you have asked


Thank You

cheers, francis
 
M

Maureen

Thanks to all. Your suggestions worked.

Bernie Deitrick said:
Use + as Or within an array formula:

=SUM(('Test Map'!G2:G124="R")*(('Test Map'!I2:I124="Anchor")+('Test Map'!I2:I124="A")))


HTH,
Bernie
MS Excel MVP
 
Top