View Single Post
  #2   Report Post  
bj
 
Posts: n/a
Default

try
=sumproduct(--(A1:A2000="Res"),--(B1:B2000="001"))
if the 001 is text format
=sumproduct(--(A1:A2000="Res"),(B1:B2000=1))
if the 001 is numeric.
and the same for 002

The range in the sumproduct needs to adjusted to cover the range you need.
You cannot just Select A:A and B:B.


"Maggie" wrote:

In a worksheet I have two columns one has a type and the second has a number.
ex. RES(residential), COM(commercial) in column one and the corresponding
numbers 001,002 are both RES numerical types. I want to be able to count them
individually by the type they fall into. ex. RES has 1200 (type 001) and RES
also has 1000 (type 002). The result desired would be RES..... 001.....1200
and next serch in the next cell be RES.....002.......1000. I was trying to
use a countif(and statement and it would bring back to few arguments. Can you
help.
--
Maggie