Counting Problem

  • Thread starter Andrew Mackenzie
  • Start date
A

Andrew Mackenzie

Hi All,

Would appreciate any help with this one.

I have a table of date with a column range named Branch which contains
either London, New York, Paris or Milan.
I have another column range named ANIU which contains either a blank or an
"X" which refers to accounts which are no longer in use.

I want a formula to count the number of accounts in both London and New York
but I want to exclude accounts that are no longer in use in London or New
York.

So far I have got:

=COUNTIF(Branch,"=London")+COUNTIF(Branch,"=New York")-countif(ANIU,"=X")

But this obvously will substract accounts not in use from the Paris and
Milan branches. Can anyone help please,

Cheers,

Andrew
 
E

Elkar

Try this:

=SUMPRODUCT((Branch="London")+(Branch="New York"),--(ANIU<>"X"))

HTH
Elkar
 
E

Eduardo

Hi,
=COUNTIFS(Branch,"London",A,"<>x")+COUNTIFS(Branch,"New York",A,"<>x")

will do the trick
 
E

Eduardo

Opps I made a mistake

=COUNTIFS(Branch,"London",ANIU,"<>x")+COUNTIFS(Branch,"New York",ANIU,"<>x")
 

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