Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Beezle
Oct 19, 2008

Happy Steve Perry Day!

ilikechapstick posted:

Quick formula question that I can't figure out.

I have some data that looks something like this:

pre:
YEAR   
2009        TRO-01
2009        TRO-01
2009        TRO-01
2008        TRO-01
2006        TRO-01
2008        TRO-01
....

2009        TRO-02
2009        TRO-03
2009        TRO-04
2008        TRO-04
2006        TRO-04
2008        TRO-04
....etc,etc

All I am trying to do is get a COUNT on the number of records for say, a TRO-01 that happened in 2009 (this would be 2). I am trying to get a COUNT (but I need it with multiple criteria), and I don't understand array functions for some reason.

EDIT:
I've tried something like
code:
{=COUNT(IF((A2:A243="2009")*(C2:C243="TRO-01"),1))}
Year is A, TRO column is C.

This should do the trick:
code:
{=SUM((A2:A243="2009")*(C2:C243="TRO-01"))}
Bonus non-array version:
code:
=SUMPRODUCT((A2:A243="2009")*(C2:C243="TRO-01"))
Both assuming the year's stored as text as per your original function, otherwise lose the double quotes obviously :)

Adbot
ADBOT LOVES YOU

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply