View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
Scott Stedman Scott Stedman is offline
external usenet poster
 
Posts: 3
Default Countif using two columns?

On May 6, 10:31*am, Claus Busch wrote:
Hi Scott,

Am Fri, 6 May 2011 08:19:09 -0700 (PDT) schrieb Scott Stedman:

I have a list of oil and gas wells by county and status. For example:


County * * Status
SEWARD * * SI
SEWARD * * Active
STEVENS * *Active
STEVENS * *SI
HASKELL * *Active
HASKELL * *SI
HASKELL * *Active


I want can easily use COUNITF to show that I have three SI (shut in)
wells and four active wells but I want to expand that data to show how
many SI and Active wells I have in each county. Is this possible?


try it with a Pivot-Table
or use formula for e.g. SEWARD and SI:
=SUMPRODUCT(--(A1:A100="SEWARD"),--(B1:B100="SI"))

Regards
Claus Busch
--
Win XP PRof SP2 / Vista Ultimate SP2
Office 2003 SP2 /2007 Ultimate SP2


Thanks for reply. Forgive my ignorance - what is the purpose of the --
you have in the function. I am an "advanced novice" and have not used
SUMPRODUCT much.