problem with conditional in if

F

Frank

Is there a problem in excel when doing a conditional with a string like
"timeDH"? as it is in the examples and if I change it to use another
column that has a number the conditional works just fine so my format is
good. But it seems you need to refer to a cell with that value instead
of the number it's self too, strange.

=SUM(IF(('raw stats'!$A$1:$A$500="timeDH"), 'raw stats'!$D$1:$D$500))
 
B

Bob Phillips

Frank,

This works

=SUM(IF('raw stats'!$A$1:$A$500="timeDH", 'raw stats'!$D$1:$D$500))

It's an array formula, so enter with Ctrl-Shift-Enter

You could do it just as easily with

=SUMIF('raw stats'!$A$1:$A$500,"timeDH",'raw stats'!$D$1:$D$500)

which is not an array formula

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 

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